Make all types support "!" so "if (!foo)" works reliably for all objects.
This commit is contained in:
@@ -0,0 +1 @@
|
||||
IO.print(null) // expect: null
|
||||
@@ -0,0 +1 @@
|
||||
IO.print(!null) // expect: true
|
||||
@@ -0,0 +1,4 @@
|
||||
IO.print(null is Null) // expect: true
|
||||
IO.print(null is Object) // expect: true
|
||||
IO.print(null is Bool) // expect: false
|
||||
IO.print(null.type == Null) // expect: true
|
||||
Reference in New Issue
Block a user