Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/main/java/com/sercapnp/lang/Capnp.flex
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,8 @@ IDENTIFIER = [A-Za-z_][A-Za-z_0-9]*
"}" { return CapnpTypes.RIGHT_BRACE; }
"[" { return CapnpTypes.LEFT_BRACKET; }
"]" { return CapnpTypes.RIGHT_BRACKET; }
"(" { return CapnpTypes.LEFT_PAREN; }
")" { return CapnpTypes.RIGHT_PAREN; }

({WHITE_SPACE})+ { return TokenType.WHITE_SPACE; }
[^] { return TokenType.BAD_CHARACTER; }
2 changes: 2 additions & 0 deletions src/main/java/com/sercapnp/lang/CapnpTypes.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ public interface CapnpTypes {
IElementType RIGHT_BRACE = new CapnpTokenType("RIGHT_BRACE");
IElementType LEFT_BRACKET = new CapnpTokenType("LEFT_BRACKET");
IElementType RIGHT_BRACKET = new CapnpTokenType("RIGHT_BRACKET");
IElementType LEFT_PAREN = new CapnpTokenType("LEFT_PAREN");
IElementType RIGHT_PAREN = new CapnpTokenType("RIGHT_PAREN");
}


Expand Down