File tree 1 file changed +9
-0
lines changed 1 file changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -2734,6 +2734,11 @@ static AstStructType* parse_struct(OnyxParser* parser) {
2734
2734
bh_arr_clear (member_list_temp );
2735
2735
while (!consume_token_if_next (parser , ':' )) {
2736
2736
if (parser -> hit_unexpected_token ) return NULL ;
2737
+ if (parser -> curr -> type == Token_Type_Doc_Comment ) {
2738
+ consume_token (parser );
2739
+ continue ;
2740
+ }
2741
+
2737
2742
bh_arr_push (member_list_temp , expect_token (parser , Token_Type_Symbol ));
2738
2743
2739
2744
if (parser -> curr -> type != ':' )
@@ -3670,6 +3675,10 @@ static AstEnumType* parse_enum_declaration(OnyxParser* parser) {
3670
3675
3671
3676
while (!consume_token_if_next (parser , '}' )) {
3672
3677
if (parser -> hit_unexpected_token ) return enum_node ;
3678
+ if (parser -> curr -> type == Token_Type_Doc_Comment ) {
3679
+ consume_token (parser );
3680
+ continue ;
3681
+ }
3673
3682
3674
3683
AstEnumValue * evalue = make_node (AstEnumValue , Ast_Kind_Enum_Value );
3675
3684
evalue -> token = expect_token (parser , Token_Type_Symbol );
You can’t perform that action at this time.
0 commit comments