pub enum CSharpTokenType {
Show 248 variants
Whitespace,
Newline,
Comment,
Identifier,
Number,
String,
Character,
VerbatimString,
InterpolatedString,
NumberLiteral,
StringLiteral,
CharLiteral,
Abstract,
As,
Base,
Bool,
Break,
Byte,
Case,
Catch,
Char,
Checked,
Class,
Const,
Continue,
Decimal,
Default,
Delegate,
Do,
Double,
Else,
Enum,
Event,
Explicit,
Extern,
False,
Finally,
Fixed,
Float,
For,
Foreach,
Goto,
If,
Implicit,
In,
Int,
Interface,
Internal,
Is,
Lock,
Long,
Namespace,
New,
Null,
Object,
Operator,
Out,
Override,
Params,
Private,
Protected,
Public,
Readonly,
Ref,
Return,
Sbyte,
Sealed,
Short,
Sizeof,
Stackalloc,
Static,
Struct,
Switch,
This,
Throw,
True,
Try,
Typeof,
Uint,
Ulong,
Unchecked,
Unsafe,
Ushort,
Using,
Virtual,
Void,
Volatile,
While,
AbstractKeyword,
AsKeyword,
BaseKeyword,
BoolKeyword,
BreakKeyword,
ByteKeyword,
CaseKeyword,
CatchKeyword,
CharKeyword,
CheckedKeyword,
ClassKeyword,
ConstKeyword,
ContinueKeyword,
DecimalKeyword,
DefaultKeyword,
DelegateKeyword,
DoKeyword,
DoubleKeyword,
ElseKeyword,
EnumKeyword,
EventKeyword,
ExplicitKeyword,
ExternKeyword,
FalseKeyword,
FinallyKeyword,
FixedKeyword,
FloatKeyword,
ForKeyword,
ForeachKeyword,
GotoKeyword,
IfKeyword,
ImplicitKeyword,
InKeyword,
IntKeyword,
InterfaceKeyword,
InternalKeyword,
IsKeyword,
LockKeyword,
LongKeyword,
NamespaceKeyword,
NewKeyword,
NullKeyword,
ObjectKeyword,
OperatorKeyword,
OutKeyword,
OverrideKeyword,
ParamsKeyword,
PrivateKeyword,
ProtectedKeyword,
PublicKeyword,
ReadonlyKeyword,
RefKeyword,
ReturnKeyword,
SbyteKeyword,
SealedKeyword,
ShortKeyword,
SizeofKeyword,
StackallocKeyword,
StaticKeyword,
StringKeyword,
StructKeyword,
SwitchKeyword,
ThisKeyword,
ThrowKeyword,
TrueKeyword,
TryKeyword,
TypeofKeyword,
UintKeyword,
UlongKeyword,
UncheckedKeyword,
UnsafeKeyword,
UshortKeyword,
UsingKeyword,
VirtualKeyword,
VoidKeyword,
VolatileKeyword,
WhileKeyword,
AddKeyword,
AliasKeyword,
AscendingKeyword,
ByKeyword,
DescendingKeyword,
FromKeyword,
GetKeyword,
GlobalKeyword,
GroupKeyword,
IntoKeyword,
JoinKeyword,
LetKeyword,
OrderbyKeyword,
PartialKeyword,
RemoveKeyword,
SelectKeyword,
SetKeyword,
ValueKeyword,
VarKeyword,
WhereKeyword,
YieldKeyword,
Plus,
Minus,
Star,
Slash,
Percent,
Ampersand,
Pipe,
Caret,
Tilde,
BitAnd,
BitOr,
BitXor,
BitNot,
LeftShift,
RightShift,
Equal,
NotEqual,
Less,
LessEqual,
Greater,
GreaterEqual,
LogicalAnd,
LogicalOr,
LogicalNot,
Question,
QuestionQuestion,
Increment,
Decrement,
Arrow,
Lambda,
Assign,
PlusAssign,
MinusAssign,
StarAssign,
SlashAssign,
PercentAssign,
AmpersandAssign,
PipeAssign,
CaretAssign,
LeftShiftAssign,
RightShiftAssign,
QuestionQuestionAssign,
AndAssign,
OrAssign,
XorAssign,
LeftParen,
RightParen,
LeftBracket,
RightBracket,
LeftBrace,
RightBrace,
Comma,
Semicolon,
Colon,
ColonColon,
Dot,
QuestionDot,
At,
Hash,
Dollar,
Eof,
Error,
}Expand description
C# token type
Variants§
Whitespace
Whitespace characters (spaces, tabs)
Newline
Newline characters
Comment
Comments (both single-line and multi-line)
Identifier
Identifiers (variable names, function names, etc.)
Number
Number literals (integer and floating-point)
String
String literals (e.g., “hello”)
Character
Character literals (e.g., ‘a’)
VerbatimString
Verbatim string literals (e.g., @“hello”)
InterpolatedString
Interpolated string literals (e.g., $“hello {name}”)
NumberLiteral
Number literals
StringLiteral
String literals
CharLiteral
Character literals
Abstract
As
Base
Bool
Break
Byte
Case
Catch
Char
Checked
Class
Const
Continue
Decimal
Default
Delegate
Do
Double
Else
Enum
Event
Explicit
Extern
False
Finally
Fixed
Float
For
Foreach
Goto
If
Implicit
In
Int
Interface
Internal
Is
Lock
Long
Namespace
New
Null
Object
Operator
Out
Override
Params
Private
Protected
Public
Readonly
Ref
Return
Sbyte
Sealed
Short
Sizeof
Stackalloc
Static
Struct
Switch
This
Throw
True
Try
Typeof
Uint
Ulong
Unchecked
Unsafe
Ushort
Using
Virtual
Void
Volatile
While
AbstractKeyword
AsKeyword
BaseKeyword
BoolKeyword
BreakKeyword
ByteKeyword
CaseKeyword
CatchKeyword
CharKeyword
CheckedKeyword
ClassKeyword
ConstKeyword
ContinueKeyword
DecimalKeyword
DefaultKeyword
DelegateKeyword
DoKeyword
DoubleKeyword
ElseKeyword
EnumKeyword
EventKeyword
ExplicitKeyword
ExternKeyword
FalseKeyword
FinallyKeyword
FixedKeyword
FloatKeyword
ForKeyword
ForeachKeyword
GotoKeyword
IfKeyword
ImplicitKeyword
InKeyword
IntKeyword
InterfaceKeyword
InternalKeyword
IsKeyword
LockKeyword
LongKeyword
NamespaceKeyword
NewKeyword
NullKeyword
ObjectKeyword
OperatorKeyword
OutKeyword
OverrideKeyword
ParamsKeyword
PrivateKeyword
ProtectedKeyword
PublicKeyword
ReadonlyKeyword
RefKeyword
ReturnKeyword
SbyteKeyword
SealedKeyword
ShortKeyword
SizeofKeyword
StackallocKeyword
StaticKeyword
StringKeyword
StructKeyword
SwitchKeyword
ThisKeyword
ThrowKeyword
TrueKeyword
TryKeyword
TypeofKeyword
UintKeyword
UlongKeyword
UncheckedKeyword
UnsafeKeyword
UshortKeyword
UsingKeyword
VirtualKeyword
VoidKeyword
VolatileKeyword
WhileKeyword
AddKeyword
AliasKeyword
AscendingKeyword
ByKeyword
DescendingKeyword
FromKeyword
GetKeyword
GlobalKeyword
GroupKeyword
IntoKeyword
JoinKeyword
LetKeyword
OrderbyKeyword
PartialKeyword
RemoveKeyword
SelectKeyword
SetKeyword
ValueKeyword
VarKeyword
WhereKeyword
YieldKeyword
Plus
Minus
Star
Slash
Percent
Ampersand
Pipe
Caret
Tilde
BitAnd
BitOr
BitXor
BitNot
LeftShift
RightShift
Equal
NotEqual
Less
LessEqual
Greater
GreaterEqual
LogicalAnd
LogicalOr
LogicalNot
Question
QuestionQuestion
Increment
Decrement
Arrow
Lambda
Assign
PlusAssign
MinusAssign
StarAssign
SlashAssign
PercentAssign
AmpersandAssign
PipeAssign
CaretAssign
LeftShiftAssign
RightShiftAssign
QuestionQuestionAssign
AndAssign
OrAssign
XorAssign
LeftParen
RightParen
LeftBracket
RightBracket
LeftBrace
RightBrace
Comma
Semicolon
Colon
ColonColon
Dot
QuestionDot
At
Hash
Dollar
Eof
End of file marker
Error
Error token
Trait Implementations§
Source§impl Clone for CSharpTokenType
impl Clone for CSharpTokenType
Source§fn clone(&self) -> CSharpTokenType
fn clone(&self) -> CSharpTokenType
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CSharpTokenType
impl Debug for CSharpTokenType
Source§impl<'de> Deserialize<'de> for CSharpTokenType
impl<'de> Deserialize<'de> for CSharpTokenType
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<CSharpTokenType> for CSharpElementType
impl From<CSharpTokenType> for CSharpElementType
Source§fn from(token: CSharpTokenType) -> Self
fn from(token: CSharpTokenType) -> Self
Converts to this type from the input type.
Source§impl Hash for CSharpTokenType
impl Hash for CSharpTokenType
Source§impl Ord for CSharpTokenType
impl Ord for CSharpTokenType
Source§fn cmp(&self, other: &CSharpTokenType) -> Ordering
fn cmp(&self, other: &CSharpTokenType) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for CSharpTokenType
impl PartialEq for CSharpTokenType
Source§impl PartialOrd for CSharpTokenType
impl PartialOrd for CSharpTokenType
Source§impl Serialize for CSharpTokenType
impl Serialize for CSharpTokenType
Source§impl TokenType for CSharpTokenType
impl TokenType for CSharpTokenType
Source§const END_OF_STREAM: Self = Self::Eof
const END_OF_STREAM: Self = Self::Eof
A constant representing the end of the input stream. Read more
Source§type Role = UniversalTokenRole
type Role = UniversalTokenRole
The associated role type for this token kind.
Source§fn is_ignored(&self) -> bool
fn is_ignored(&self) -> bool
Returns true if this token represents trivia (whitespace, comments, etc.). Read more
Source§fn is_comment(&self) -> bool
fn is_comment(&self) -> bool
Returns true if this token represents a comment. Read more
Source§fn is_whitespace(&self) -> bool
fn is_whitespace(&self) -> bool
Returns true if this token represents whitespace. Read more
Source§fn is_role(&self, role: Self::Role) -> bool
fn is_role(&self, role: Self::Role) -> bool
Returns true if this token matches the specified language-specific role.
Source§fn is_universal(&self, role: UniversalTokenRole) -> bool
fn is_universal(&self, role: UniversalTokenRole) -> bool
Returns true if this token matches the specified universal role.
Source§fn is_error(&self) -> bool
fn is_error(&self) -> bool
Returns true if this token represents an error condition. Read more
Source§fn is_end_of_stream(&self) -> bool
fn is_end_of_stream(&self) -> bool
Returns true if this token represents the end of the input stream. Read more
impl Copy for CSharpTokenType
impl Eq for CSharpTokenType
impl StructuralPartialEq for CSharpTokenType
Auto Trait Implementations§
impl Freeze for CSharpTokenType
impl RefUnwindSafe for CSharpTokenType
impl Send for CSharpTokenType
impl Sync for CSharpTokenType
impl Unpin for CSharpTokenType
impl UnwindSafe for CSharpTokenType
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
Mutably borrows from an owned value. Read more