Refactor VM and operators
This commit is contained in:
@@ -18,6 +18,10 @@ func (n *Null) String() string {
|
||||
return n.Inspect()
|
||||
}
|
||||
|
||||
func (n *Null) LogicalNot() Object {
|
||||
return &Boolean{!n.Bool()}
|
||||
}
|
||||
|
||||
func (n *Null) Compare(other Object) int {
|
||||
if _, ok := other.(*Null); ok {
|
||||
return 0
|
||||
|
||||
Reference in New Issue
Block a user