Mode constants written to file as tokens and channels.

I mean:

```Java
public static final int M1=1, M2=2;
```

instead of

```Java
public static final int M1=1;
public static final int M2=2;
```
This commit is contained in:
Ivan Kochurkin 2017-01-08 18:20:34 +03:00
parent e9e83a69e7
commit 00d0ba129b
1 changed files with 5 additions and 3 deletions

View File

@ -898,10 +898,12 @@ public class <lexer.name> extends <superClass; null="Lexer"> {
<lexer.tokens:{k | <k>=<lexer.tokens.(k)>}; separator=", ", wrap, anchor>;
<if(lexer.channels)>
public static final int
<lexer.channels:{k | <k>=<lexer.channels.(k)>}; separator=", ", wrap, anchor>;
<lexer.channels:{c | <c>=<lexer.channels.(c)>}; separator=", ", wrap, anchor>;
<endif>
<if(rest(lexer.modes))>
public static final int
<rest(lexer.modes):{m | <m>=<i>}; separator=", ", wrap, anchor>;
<endif>
<rest(lexer.modes):{m| public static final int <m> = <i>;}; separator="\n">
public static String[] channelNames = {
"DEFAULT_TOKEN_CHANNEL", "HIDDEN", <lexer.channels:{c| "<c>"}; separator=", ", wrap, anchor>
};