diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/cli/runtime/Num.cs | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/cli/runtime/Num.cs b/src/cli/runtime/Num.cs index 32f451b7..682381f1 100644 --- a/src/cli/runtime/Num.cs +++ b/src/cli/runtime/Num.cs @@ -83,8 +83,18 @@ static public Num from(Object x) else throw new ArgumentException("Cannot convert argument: " + x + " to Num"); } - } - + }
+
+
+ virtual public byte byteValue()
+ {
+ return checked((byte)intValue());
+ }
+
+ virtual public short shortValue()
+ {
+ return checked((short)intValue());
+ } abstract public double doubleValue(); |