fix: 语法问题
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
{
|
{
|
||||||
generate=[token-case="as-is" element-case="as-is"]
|
generate=[token-case="as-is" element-case="as-is"]
|
||||||
parserClass="me.zhouxi.slint.lang.parser.SlintParser"
|
parserClass="me.zhouxi.slint.lang.parser.SlintParser"
|
||||||
|
parserUtilClass="me.zhouxi.slint.lang.psi.SlintParserUtil"
|
||||||
implements="me.zhouxi.slint.lang.psi.SlintPsiElement"
|
implements="me.zhouxi.slint.lang.psi.SlintPsiElement"
|
||||||
extends="me.zhouxi.slint.lang.psi.impl.SlintPsiElementImpl"
|
extends="me.zhouxi.slint.lang.psi.impl.SlintPsiElementImpl"
|
||||||
elementTypeHolderClass="me.zhouxi.slint.lang.psi.SlintTypes"
|
elementTypeHolderClass="me.zhouxi.slint.lang.psi.SlintTypes"
|
||||||
@@ -10,57 +11,58 @@
|
|||||||
psiImplClassSuffix="Impl"
|
psiImplClassSuffix="Impl"
|
||||||
psiPackage="me.zhouxi.slint.lang.psi"
|
psiPackage="me.zhouxi.slint.lang.psi"
|
||||||
psiImplPackage="me.zhouxi.slint.lang.psi.impl"
|
psiImplPackage="me.zhouxi.slint.lang.psi.impl"
|
||||||
tokens=[
|
|
||||||
Comma = ","
|
|
||||||
FatArrow = "=>"
|
|
||||||
DoubleArrow = "<=>"
|
|
||||||
PlusEqual = "+="
|
|
||||||
MinusEqual = "-="
|
|
||||||
StarEqual = "*="
|
|
||||||
DivEqual = "/="
|
|
||||||
LessEqual = "<="
|
|
||||||
GreaterEqual = ">="
|
|
||||||
EqualEqual = "=="
|
|
||||||
NotEqual = "!="
|
|
||||||
ColonEqual = ":="
|
|
||||||
Arrow = "->"
|
|
||||||
OrOr = "||"
|
|
||||||
AndAnd = "&&"
|
|
||||||
LBrace = "{"
|
|
||||||
RBrace = "}"
|
|
||||||
LParent = "("
|
|
||||||
RParent = ")"
|
|
||||||
LAngle = "<"
|
|
||||||
RAngle = ">"
|
|
||||||
LBracket = "["
|
|
||||||
RBracket = "]"
|
|
||||||
Plus = "+"
|
|
||||||
Minus = "-"
|
|
||||||
Star = "*"
|
|
||||||
Div = "/"
|
|
||||||
Equal = "="
|
|
||||||
Colon = ":"
|
|
||||||
Comma = ","
|
|
||||||
Semicolon = ";"
|
|
||||||
Bang = "!"
|
|
||||||
Dot = "."
|
|
||||||
Question = "?"
|
|
||||||
Dollar = "$"
|
|
||||||
At = "@"
|
|
||||||
Pipe = "|"
|
|
||||||
Percent = "%"
|
|
||||||
Whitespace = "regexp:(\s+)"
|
|
||||||
NumberLiteral = "regexp:\d+(\.(\d+)?)?([a-z]+|%)?"
|
|
||||||
Identifier = "regexp:^[a-zA-Z_][A-Za-z0-9\-_]*"
|
|
||||||
ColorLiteral = "regexp:#([a-zA-Z0-9]+)"
|
|
||||||
StringLiteral = 'regexp:(^"[^"\r\n]*")'
|
|
||||||
LineComment = 'regexp:^//[^\r\n]*'
|
|
||||||
BlockComment = 'regexp:/\*[\s\S]*?\*/'
|
|
||||||
|
|
||||||
]
|
|
||||||
extends(".*Expression")=Expression
|
extends(".*Expression")=Expression
|
||||||
implements(".*Keyword")=["me.zhouxi.slint.lang.psi.keyword.SlintPsiKeywordIdentifier"]
|
implements(".*Keyword")=["me.zhouxi.slint.lang.psi.SlintPsiKeyword"]
|
||||||
mixin(".*Keyword")="me.zhouxi.slint.lang.psi.keyword.SlintPsiKeywordIdentifierImpl"
|
extends(".*Keyword")="me.zhouxi.slint.lang.psi.SlintPsiKeyword.Impl"
|
||||||
|
elementTypeFactory(".*Keyword")="me.zhouxi.slint.lang.psi.SlintPsiKeyword.type"
|
||||||
|
tokens=[
|
||||||
|
Comma = ","
|
||||||
|
FatArrow = "=>"
|
||||||
|
DoubleArrow = "<=>"
|
||||||
|
PlusEqual = "+="
|
||||||
|
MinusEqual = "-="
|
||||||
|
StarEqual = "*="
|
||||||
|
DivEqual = "/="
|
||||||
|
LessEqual = "<="
|
||||||
|
GreaterEqual = ">="
|
||||||
|
EqualEqual = "=="
|
||||||
|
NotEqual = "!="
|
||||||
|
ColonEqual = ":="
|
||||||
|
Arrow = "->"
|
||||||
|
OrOr = "||"
|
||||||
|
AndAnd = "&&"
|
||||||
|
LBrace = "{"
|
||||||
|
RBrace = "}"
|
||||||
|
LParent = "("
|
||||||
|
RParent = ")"
|
||||||
|
LAngle = "<"
|
||||||
|
RAngle = ">"
|
||||||
|
LBracket = "["
|
||||||
|
RBracket = "]"
|
||||||
|
Plus = "+"
|
||||||
|
Minus = "-"
|
||||||
|
Star = "*"
|
||||||
|
Div = "/"
|
||||||
|
Equal = "="
|
||||||
|
Colon = ":"
|
||||||
|
Comma = ","
|
||||||
|
Semicolon = ";"
|
||||||
|
Bang = "!"
|
||||||
|
Dot = "."
|
||||||
|
Question = "?"
|
||||||
|
Dollar = "$"
|
||||||
|
At = "@"
|
||||||
|
Pipe = "|"
|
||||||
|
Percent = "%"
|
||||||
|
Whitespace = "regexp:(\s+)"
|
||||||
|
NumberLiteral = "regexp:\d+(\.(\d+)?)?([a-z]+|%)?"
|
||||||
|
Identifier = "regexp:^[a-zA-Z_][A-Za-z0-9\-_]*"
|
||||||
|
ColorLiteral = "regexp:#([a-zA-Z0-9]+)"
|
||||||
|
StringLiteral = 'regexp:(^"[^"\r\n]*")'
|
||||||
|
LineComment = 'regexp:^//[^\r\n]*'
|
||||||
|
BlockComment = 'regexp:/\*[\s\S]*?\*/'
|
||||||
|
|
||||||
|
]
|
||||||
}
|
}
|
||||||
//
|
//
|
||||||
Document ::= DocumentElement*
|
Document ::= DocumentElement*
|
||||||
|
|||||||
Reference in New Issue
Block a user