@Override protected void lookAhead(Lexer baseLexer) { IElementType currentToken = baseLexer.getTokenType(); if (currentToken == NeonTokenTypes.NEON_LITERAL && KEYWORDS.contains(baseLexer.getTokenText())) { advanceLexer(baseLexer); replaceCachedType(0, NeonTokenTypes.NEON_KEYWORD); } else if (currentToken == NeonTokenTypes.NEON_LITERAL || currentToken == NeonTokenTypes.NEON_STRING) { advanceLexer(baseLexer); if (baseLexer.getTokenType() == NeonTokenTypes.NEON_WHITESPACE) { advanceLexer(baseLexer); } if (baseLexer.getTokenType() == NeonTokenTypes.NEON_COLON) { advanceLexer(baseLexer); replaceCachedType(0, NeonTokenTypes.NEON_KEY); } } else { super.lookAhead(baseLexer); } }
@Override protected void lookAhead(Lexer baseLexer) { super.lookAhead(baseLexer); }