Reworked bound variables into specific LuaType class instead of anonymous objects
This commit is contained in:
@@ -1,9 +1,11 @@
|
||||
namespace Upsilon.BaseTypes.Number
|
||||
{
|
||||
public abstract class Number
|
||||
public abstract class Number : LuaType
|
||||
{
|
||||
protected abstract bool IsFloat { get; }
|
||||
|
||||
public override Type Type => Type.Number;
|
||||
|
||||
#region Binary Operators
|
||||
|
||||
public static Number operator + (Number a, Number b)
|
||||
|
||||
@@ -21,5 +21,11 @@ namespace Upsilon.BaseTypes.Number
|
||||
{
|
||||
return Value.ToString(CultureInfo.InvariantCulture);
|
||||
}
|
||||
|
||||
public static implicit operator double(NumberDouble n)
|
||||
{
|
||||
return n.Value;
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -23,7 +23,7 @@ namespace Upsilon.BaseTypes.Number
|
||||
return Value.ToString(CultureInfo.InvariantCulture);
|
||||
}
|
||||
|
||||
public static explicit operator long(NumberLong n)
|
||||
public static implicit operator long(NumberLong n)
|
||||
{
|
||||
return n.Value;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user