type checking and error handling for builtins improved.
This commit is contained in:
@@ -6,6 +6,10 @@ type Integer struct {
|
||||
Value int64
|
||||
}
|
||||
|
||||
func (i *Integer) Bool() bool {
|
||||
return i.Value != 0
|
||||
}
|
||||
|
||||
func (i *Integer) Type() ObjectType {
|
||||
return INTEGER_OBJ
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user