Remove null
This commit is contained in:
16
globals.kl
16
globals.kl
@@ -4,7 +4,7 @@
|
||||
test_function :: (thing: int): *int
|
||||
function_type: test_function
|
||||
const_function_alias :: test_function
|
||||
null_function: (t: int): *int = null
|
||||
// null_function: (t: int): *int = null
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Booleans
|
||||
@@ -15,9 +15,9 @@ value_of_bool: int = cast(boolean: int)
|
||||
//-----------------------------------------------------------------------------
|
||||
// Nulls
|
||||
//-----------------------------------------------------------------------------
|
||||
int_null: int = null
|
||||
str_null: String = null
|
||||
bool_null: bool = null
|
||||
// int_null: int = null
|
||||
// str_null: String = null
|
||||
// bool_null: bool = null
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// Compound expressions
|
||||
@@ -25,7 +25,7 @@ bool_null: bool = null
|
||||
array1: [4]int = [4]int(1,2,3,4)
|
||||
array2 := [32]int(1,2,3,4)
|
||||
array3 := [32]int(
|
||||
[0] = null,
|
||||
[0] = 0,
|
||||
[1] = 1,
|
||||
[2] = 2,
|
||||
[31] = 31,
|
||||
@@ -50,9 +50,9 @@ implicit_str :: "Hello world"
|
||||
//-----------------------------------------------------------------------------
|
||||
// Pointers
|
||||
//-----------------------------------------------------------------------------
|
||||
pointer1: *int = null
|
||||
pointer2: *int = pointer1
|
||||
pointer3: **int = null
|
||||
// pointer1: *int = 0
|
||||
// pointer2: *int = pointer1
|
||||
// pointer3: **int = 0
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
// String types
|
||||
|
||||
Reference in New Issue
Block a user