#[repr(u16)]pub enum SyntaxKind {
Show 96 variants
Error = 0,
Eof = 1,
Whitespace = 2,
Comment = 3,
StringLiteral = 4,
NumberLiteral = 5,
ColorLiteral = 6,
Identifier = 7,
DoubleArrow = 8,
PlusEqual = 9,
MinusEqual = 10,
StarEqual = 11,
DivEqual = 12,
LessEqual = 13,
GreaterEqual = 14,
EqualEqual = 15,
NotEqual = 16,
ColonEqual = 17,
FatArrow = 18,
Arrow = 19,
OrOr = 20,
AndAnd = 21,
LBrace = 22,
RBrace = 23,
LParent = 24,
RParent = 25,
LAngle = 26,
RAngle = 27,
LBracket = 28,
RBracket = 29,
Plus = 30,
Minus = 31,
Star = 32,
Div = 33,
Equal = 34,
Colon = 35,
Comma = 36,
Semicolon = 37,
Bang = 38,
Dot = 39,
Question = 40,
Dollar = 41,
At = 42,
Document = 43,
Component = 44,
SubElement = 45,
Element = 46,
RepeatedElement = 47,
RepeatedIndex = 48,
ConditionalElement = 49,
CallbackDeclaration = 50,
ReturnType = 51,
CallbackConnection = 52,
PropertyDeclaration = 53,
PropertyAnimation = 54,
QualifiedName = 55,
DeclaredIdentifier = 56,
ChildrenPlaceholder = 57,
Binding = 58,
TwoWayBinding = 59,
BindingExpression = 60,
CodeBlock = 61,
ReturnStatement = 62,
Expression = 63,
StringTemplate = 64,
AtImageUrl = 65,
AtLinearGradient = 66,
FunctionCallExpression = 67,
IndexExpression = 68,
SelfAssignment = 69,
ConditionalExpression = 70,
BinaryExpression = 71,
UnaryOpExpression = 72,
MemberAccess = 73,
Array = 74,
ObjectLiteral = 75,
ObjectMember = 76,
States = 77,
State = 78,
StatePropertyChange = 79,
Transitions = 80,
Transition = 81,
ExportsList = 82,
ExportSpecifier = 83,
ExportIdentifier = 84,
ExportName = 85,
ImportSpecifier = 86,
ImportIdentifierList = 87,
ImportIdentifier = 88,
ExternalName = 89,
InternalName = 90,
Type = 91,
ObjectType = 92,
ObjectTypeMember = 93,
ArrayType = 94,
StructDeclaration = 95,
}
Variants§
Error = 0
Eof = 1
Whitespace = 2
Token
Comment = 3
Token
StringLiteral = 4
Token
NumberLiteral = 5
Token
ColorLiteral = 6
Token
Identifier = 7
Token
DoubleArrow = 8
Token
PlusEqual = 9
Token
MinusEqual = 10
Token
StarEqual = 11
Token
DivEqual = 12
Token
LessEqual = 13
Token
GreaterEqual = 14
Token
EqualEqual = 15
Token
NotEqual = 16
Token
ColonEqual = 17
Token
FatArrow = 18
Token
Arrow = 19
Token
OrOr = 20
Token
AndAnd = 21
Token
LBrace = 22
Token
RBrace = 23
Token
LParent = 24
Token
RParent = 25
Token
LAngle = 26
Token
RAngle = 27
Token
LBracket = 28
Token
RBracket = 29
Token
Plus = 30
Token
Minus = 31
Token
Star = 32
Token
Div = 33
Token
Equal = 34
Token
Colon = 35
Token
Comma = 36
Token
Semicolon = 37
Token
Bang = 38
Token
Dot = 39
Token
Question = 40
Token
Dollar = 41
Token
At = 42
Token
Document = 43
Component = 44
DeclaredIdentifier := Element { ... }
SubElement = 45
id := Element { ... }
Element = 46
RepeatedElement = 47
RepeatedIndex = 48
ConditionalElement = 49
CallbackDeclaration = 50
ReturnType = 51
-> type
(but without the ->)
CallbackConnection = 52
PropertyDeclaration = 53
Declaration of a property.
PropertyAnimation = 54
QualifiedName are the properties name
QualifiedName = 55
wraps Identifiers, like Rectangle
or SomeModule.SomeType
DeclaredIdentifier = 56
Wraps single identifier (to disambiguate when there are other identifier in the production)
ChildrenPlaceholder = 57
Binding = 58
TwoWayBinding = 59
xxx <=> something
BindingExpression = 60
the right-hand-side of a binding
CodeBlock = 61
ReturnStatement = 62
Expression = 63
StringTemplate = 64
Concatenate the Expressions to make a string (usually expended from a template string)
AtImageUrl = 65
@image-url("foo.png")
AtLinearGradient = 66
@linear-gradient(...)
FunctionCallExpression = 67
expression()
IndexExpression = 68
expression[index]
SelfAssignment = 69
expression += expression
ConditionalExpression = 70
condition ? first : second
BinaryExpression = 71
expr + expr
UnaryOpExpression = 72
- expr
MemberAccess = 73
(foo).bar
, where foo
is the base expression, and bar
is a Identifier.
Array = 74
[ ... ]
ObjectLiteral = 75
{ foo: bar }
ObjectMember = 76
foo: bar
inside an ObjectLiteral
States = 77
states: [...]
State = 78
The DeclaredIdentifier is the state name. The Expression, if any, is the condition.
StatePropertyChange = 79
binding within a state
Transitions = 80
transitions: [...]
Transition = 81
There is an identifier “in” or “out”, the DeclaredIdentifier is the state name
ExportsList = 82
Export a set of declared components by name
ExportSpecifier = 83
Declare the first identifier to be exported, either under its name or instead under the name of the second identifier.
ExportIdentifier = 84
ExportName = 85
ImportSpecifier = 86
import { foo, bar, baz } from “blah”; The import uri is stored as string literal.
ImportIdentifierList = 87
ImportIdentifier = 88
{ foo as bar } or just { foo }
ExternalName = 89
InternalName = 90
Type = 91
The representation of a type
ObjectType = 92
{foo: string, bar: string}
ObjectTypeMember = 93
foo: type
inside an ObjectType
ArrayType = 94
[ type ]
StructDeclaration = 95
`struct Foo := { … }
Trait Implementations§
Source§impl Clone for SyntaxKind
impl Clone for SyntaxKind
Source§fn clone(&self) -> SyntaxKind
fn clone(&self) -> SyntaxKind
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for SyntaxKind
impl Debug for SyntaxKind
Source§impl Display for SyntaxKind
impl Display for SyntaxKind
Source§impl From<SyntaxKind> for SyntaxKind
impl From<SyntaxKind> for SyntaxKind
Source§fn from(v: SyntaxKind) -> Self
fn from(v: SyntaxKind) -> Self
Source§impl From<SyntaxKind> for u16
impl From<SyntaxKind> for u16
Source§fn from(enum_value: SyntaxKind) -> Self
fn from(enum_value: SyntaxKind) -> Self
Source§impl PartialEq for SyntaxKind
impl PartialEq for SyntaxKind
Source§impl TryFrom<u16> for SyntaxKind
impl TryFrom<u16> for SyntaxKind
Source§type Error = TryFromPrimitiveError<SyntaxKind>
type Error = TryFromPrimitiveError<SyntaxKind>
Source§impl TryFromPrimitive for SyntaxKind
impl TryFromPrimitive for SyntaxKind
impl Copy for SyntaxKind
impl Eq for SyntaxKind
impl StructuralPartialEq for SyntaxKind
Auto Trait Implementations§
impl Freeze for SyntaxKind
impl RefUnwindSafe for SyntaxKind
impl Send for SyntaxKind
impl Sync for SyntaxKind
impl Unpin for SyntaxKind
impl UnwindSafe for SyntaxKind
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more