Skip to content

Commit

Permalink
Update to 0.0.16
Browse files Browse the repository at this point in the history
  • Loading branch information
lerno committed Sep 5, 2024
1 parent 8b42cb2 commit ad32cff
Show file tree
Hide file tree
Showing 9 changed files with 900 additions and 799 deletions.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,11 @@

## [Unreleased]

## [0.0.16] - 2024-09-05

- Added `+++`, `&&&`, `|||` support.
- Added support for new named parameters.

## [0.0.15] - 2024-07-03

- Added `$concat` and `$append` support.
Expand Down
1,562 changes: 790 additions & 772 deletions src/main/gen/org/c3lang/intellij/lexer/C3Lexer.java

Large diffs are not rendered by default.

100 changes: 77 additions & 23 deletions src/main/gen/org/c3lang/intellij/parser/C3Parser.java

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions src/main/gen/org/c3lang/intellij/psi/C3Arg.java

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions src/main/gen/org/c3lang/intellij/psi/C3Types.java

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions src/main/gen/org/c3lang/intellij/psi/C3Visitor.java

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions src/main/gen/org/c3lang/intellij/psi/impl/C3ArgImpl.java

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

9 changes: 5 additions & 4 deletions src/main/java/org/c3lang/intellij/C3.bnf
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,8 @@ enum_param_decl ::= type IDENT
enum_list ::= enum_constant (COMMA enum_constant ?)* COMMA?
enum_constant ::= CONST_IDENT attributes? (EQ expr)?
arg_list ::= arg (COMMA arg)* COMMA?
arg ::= param_path (EQ (expr | type))? | expr | type | KW_CT_VASPLAT LP range_exp? RP | ELLIPSIS expr
named_ident ::= CT_IDENT | HASH_IDENT | IDENT | CT_TYPE_IDENT
arg ::= (named_ident COLON (expr | type)) | param_path (EQ (expr | type))? | expr | type | KW_CT_VASPLAT LP range_exp? RP | ELLIPSIS expr


global_decl ::= KW_TLOCAL? optional_type IDENT (global_multi_declaration | global_single_declaration) EOS
Expand Down Expand Up @@ -289,7 +290,7 @@ unary_op ::= AMP | AND | STAR | PLUS | MINUS | BIT_NOT | BANG | PLUSPLUS | MINUS
mult_bin_op ::= STAR | DIV | MOD { name = "operator" }
shift_bin_op ::= SHL | SHR { name = "operator "}
bit_bin_op ::= AMP | BIT_XOR | BIT_OR { name = "operator" }
add_bin_op ::= PLUS | MINUS { name = "operator" }
add_bin_op ::= PLUS | MINUS | CT_PLUS { name = "operator" }
rel_bin_op ::= LT_OP | GT_OP | LE_OP | GE_OP | EQ_OP | NE_OP { name = "operator" }

catch_unwrap_list ::= expr (COMMA expr)*
Expand Down Expand Up @@ -319,8 +320,8 @@ add_bin_expr ::= expr add_bin_op expr
bit_bin_expr ::= expr bit_bin_op expr
shift_bin_expr ::= expr shift_bin_op expr
mult_bin_expr ::= expr mult_bin_op expr
and_bin_expr ::= expr AND expr
or_bin_expr ::= expr OR expr
and_bin_expr ::= expr (AND | CT_AND) expr
or_bin_expr ::= expr (OR | CT_OR) expr

literal_expr ::= INT_LITERAL | FLOAT_LITERAL
keyword_expr ::= KW_NULL | KW_TRUE | KW_FALSE | KW_CT_VACOUNT
Expand Down
3 changes: 3 additions & 0 deletions src/main/java/org/c3lang/intellij/C3.flex
Original file line number Diff line number Diff line change
Expand Up @@ -189,6 +189,9 @@ LINE_COMMENT = "//" .*
"usz" { return C3Types.KW_USZ; }
"isz" { return C3Types.KW_ISZ; }

"&&&" { return C3Types.CT_AND; }
"|||" { return C3Types.CT_OR; }
"+++" { return C3Types.CT_PLUS; }
"..." { return C3Types.ELLIPSIS; }
"<<=" { return C3Types.SHL_ASSIGN; }
">>=" { return C3Types.SHR_ASSIGN; }
Expand Down

0 comments on commit ad32cff

Please sign in to comment.