Skip to content

Commit 6193e79

Browse files
committed
Merge branch 'master' of github.com:CppCXY/EmmyLuaCodeStyle
2 parents 4667bf9 + dbb6538 commit 6193e79

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

LuaParser/src/Lexer/LuaLexer.cpp

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -342,6 +342,17 @@ LuaTokenKind LuaLexer::Lex() {
342342
}
343343
return '#';
344344
}
345+
case '{': {
346+
// extend syntax see issue 119
347+
_reader.SaveAndNext();
348+
if (_reader.CheckNext1('@')){
349+
_reader.EatWhile([](char ch) { return lislalnum(ch); });
350+
if (_reader.CheckNext1('}')){
351+
return TK_NAME;
352+
}
353+
}
354+
return '{';
355+
}
345356
default: {
346357
if (lislalpha(_reader.GetCurrentChar())) /* identifier or reserved word? */
347358
{

0 commit comments

Comments
 (0)