Daily update on 20250305-052510 by Nitload Youmu. Additional Message : message
Signed-off-by: Nitload <YoumuLiu_NSI@whv0t.onmicrosoft.com>
This commit is contained in:
@@ -58,7 +58,7 @@ namespace StgSharp.Script.Express
|
||||
|
||||
public override IExpElementSource EqualityTypeConvert => _operand.EqualityTypeConvert;
|
||||
|
||||
public static ExpUnaryOperatorNode UnaryNegation( ExpNode operand )
|
||||
public static ExpUnaryOperatorNode UnaryMinus( ExpNode operand )
|
||||
{
|
||||
if( !operand.IsNumber ) {
|
||||
throw new ExpInvalidTypeException(
|
||||
@@ -87,5 +87,20 @@ namespace StgSharp.Script.Express
|
||||
};
|
||||
}
|
||||
|
||||
public static ExpUnaryOperatorNode UnaryPlus( ExpNode operand )
|
||||
{
|
||||
if( !operand.IsNumber ) {
|
||||
throw new ExpInvalidTypeException(
|
||||
"Number", operand.EqualityTypeConvert.Name );
|
||||
}
|
||||
bool isFloat =
|
||||
( operand._nodeFlag | ExpNodeFlag.BuiltinType_Float ) == 0;
|
||||
return new ExpUnaryOperatorNode( ExpCompile.KeyWord.SUB )
|
||||
{
|
||||
_nodeFlag = ExpNodeFlag.Operator_Unary | ExpNodeFlag.BuiltinType_Number,
|
||||
CodeConvertTemplate = "+ {0}",
|
||||
};
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user