summaryrefslogtreecommitdiff
path: root/boot/stage14.elna
diff options
context:
space:
mode:
Diffstat (limited to 'boot/stage14.elna')
-rw-r--r--boot/stage14.elna14
1 files changed, 9 insertions, 5 deletions
diff --git a/boot/stage14.elna b/boot/stage14.elna
index e7e8811..5566518 100644
--- a/boot/stage14.elna
+++ b/boot/stage14.elna
@@ -1593,18 +1593,22 @@ begin
_lexer_skip_token();
_lexer_read_token(@token_kind);
_lexer_skip_token();
- _read_type_expression();
_lexer_read_token(@token_kind);
+ name := _lexer_global_get_start();
+ name_length := _lexer_global_get_end() + -name;
+ _lexer_skip_token();
+ _lexer_read_token(@token_kind);
- if token_kind <> _lexer_token_kind_assignment() then
+ if _lexer_compare_keyword("Array", 5, name, name_length) = 1 then
(* Else we assume this is a zeroed 819200 bytes big array. *)
_write_z(" .zero 819200\0")
- else
+ elsif token_kind = _lexer_token_kind_assignment() then
(* Skip the assignment sign with surrounding whitespaces. *)
_lexer_skip_token();
- _compile_global_initializer();
- _lexer_read_token(@token_kind)
+ _compile_global_initializer()
+ else
+ _write_z(" .word 0\n\0")
end;
(* Skip semicolon and newline. *)