-
-
Notifications
You must be signed in to change notification settings - Fork 75
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#2912 Properly lex special variables followed by operator
Fixes #2912
- Loading branch information
Showing
13 changed files
with
5,942 additions
and
5,342 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
10,574 changes: 5,287 additions & 5,287 deletions
10,574
plugin/core/src/main/gen/com/perl5/lang/perl/lexer/PerlLexer.java
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
284 changes: 284 additions & 0 deletions
284
plugin/src/test/resources/highlighting/perl/syntax/doubleBuckConcat.pl.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,284 @@ | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
. | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
, | ||
PERL_COMMA => DEFAULT_COMMA | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
/ | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
\ | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
| | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
% | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
- | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
+ | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
? | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
: | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
= | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
^ | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
~ | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
! | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
@ | ||
PERL_ARRAY => DEFAULT_IDENTIFIER => TEXT | ||
a | ||
PERL_ARRAY => DEFAULT_IDENTIFIER => TEXT | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
#test; | ||
PERL_COMMENT => DEFAULT_LINE_COMMENT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
* | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
[ | ||
PERL_BRACKETS => DEFAULT_BRACKETS | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
] | ||
PERL_BRACKETS => DEFAULT_BRACKETS | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
( | ||
PERL_PARENTESS => DEFAULT_PARENTHS | ||
) | ||
PERL_PARENTESS => DEFAULT_PARENTHS | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
( | ||
PERL_PARENTESS => DEFAULT_PARENTHS | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
) | ||
PERL_PARENTESS => DEFAULT_PARENTHS | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
< | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
1 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
> | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
2 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
0 | ||
PERL_NUMBER => DEFAULT_NUMBER | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
1 | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
[ | ||
PERL_BRACKETS => DEFAULT_BRACKETS | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
] | ||
PERL_BRACKETS => DEFAULT_BRACKETS | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
& | ||
PERL_OPERATOR => DEFAULT_OPERATION_SIGN | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
` | ||
PERL_DX_STRING => DEFAULT_STRING | ||
` | ||
PERL_DX_STRING => DEFAULT_STRING | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
' | ||
PERL_SQ_STRING => DEFAULT_STRING | ||
' | ||
PERL_SQ_STRING => DEFAULT_STRING | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
$ | ||
PERL_SCALAR => DEFAULT_IDENTIFIER => TEXT | ||
" | ||
PERL_DQ_STRING => DEFAULT_STRING | ||
test | ||
PERL_DQ_STRING => DEFAULT_STRING | ||
" | ||
PERL_DQ_STRING => DEFAULT_STRING | ||
; | ||
PERL_SEMICOLON => DEFAULT_SEMICOLON |
29 changes: 29 additions & 0 deletions
29
plugin/src/test/resources/unit/perl/parser/doubleBuckConcat.code
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
$$.1; | ||
$$,1; | ||
$$/1; | ||
$$\1; | ||
$$|1; | ||
$$%; | ||
$$-1; | ||
$$+1; | ||
$$?$$:1; | ||
$$=1; | ||
$$^1; | ||
$$~1; | ||
$$!1; | ||
$$@a; | ||
$$#test; | ||
$$*1; | ||
$$[1]; | ||
$$(); | ||
($$); | ||
$$<1; | ||
$$>2; | ||
$$0; | ||
$$1; | ||
$$; | ||
[$$]; | ||
$$&; | ||
$$``; | ||
$$''; | ||
$$"test"; |
Oops, something went wrong.