pub enum AdaTokenType {
Show 116 variants
Whitespace,
Newline,
Comment,
StringLiteral,
CharacterLiteral,
NumberLiteral,
Identifier,
Abort,
Abs,
Abstract,
Accept,
Access,
Aliased,
All,
And,
Array,
At,
Begin,
Body,
Case,
Constant,
Declare,
Delay,
Delta,
Digits,
Do,
Else,
Elsif,
End,
Entry,
Exception,
Exit,
For,
Function,
Generic,
Goto,
If,
In,
Interface,
Is,
Limited,
Loop,
Mod,
New,
Not,
Null,
Of,
Or,
Others,
Out,
Overriding,
Package,
Pragma,
Private,
Procedure,
Protected,
Raise,
Range,
Record,
Rem,
Renames,
Requeue,
Return,
Reverse,
Select,
Separate,
Some,
Subtype,
Synchronized,
Tagged,
Task,
Terminate,
Then,
Type,
Until,
Use,
When,
While,
With,
Xor,
Plus,
Minus,
Star,
Slash,
Ampersand,
Eq,
Ne,
Lt,
Le,
Gt,
Ge,
Assign,
ColonEq,
Arrow,
Dot,
DotDot,
Comma,
Colon,
Semicolon,
Bar,
Pipe,
Apostrophe,
Tick,
LeftParen,
RightParen,
Box,
DoubleStar,
StarStar,
LtLt,
GtGt,
LeftBracket,
RightBracket,
LeftBrace,
RightBrace,
Eof,
Error,
}Expand description
Ada 词法单元类型
Variants§
Whitespace
Newline
Comment
StringLiteral
CharacterLiteral
NumberLiteral
Identifier
Abort
Abs
Abstract
Accept
Access
Aliased
All
And
Array
At
Begin
Body
Case
Constant
Declare
Delay
Delta
Digits
Do
Else
Elsif
End
Entry
Exception
Exit
For
Function
Generic
Goto
If
In
Interface
Is
Limited
Loop
Mod
New
Not
Null
Of
Or
Others
Out
Overriding
Package
Pragma
Private
Procedure
Protected
Raise
Range
Record
Rem
Renames
Requeue
Return
Reverse
Select
Separate
Some
Subtype
Synchronized
Tagged
Task
Terminate
Then
Type
Until
Use
When
While
With
Xor
Plus
Minus
Star
Slash
Ampersand
Eq
Ne
Lt
Le
Gt
Ge
Assign
ColonEq
Arrow
Dot
DotDot
Comma
Colon
Semicolon
Bar
Pipe
Apostrophe
Tick
LeftParen
RightParen
Box
DoubleStar
StarStar
LtLt
GtGt
LeftBracket
RightBracket
LeftBrace
RightBrace
Eof
Error
Implementations§
Source§impl AdaTokenType
impl AdaTokenType
Sourcepub fn is_keyword(&self) -> bool
pub fn is_keyword(&self) -> bool
是否为关键字
Sourcepub fn is_identifier(&self) -> bool
pub fn is_identifier(&self) -> bool
是否为标识符
Sourcepub fn is_literal(&self) -> bool
pub fn is_literal(&self) -> bool
是否为字面量
Trait Implementations§
Source§impl Clone for AdaTokenType
impl Clone for AdaTokenType
Source§fn clone(&self) -> AdaTokenType
fn clone(&self) -> AdaTokenType
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 AdaTokenType
impl Debug for AdaTokenType
Source§impl<'de> Deserialize<'de> for AdaTokenType
impl<'de> Deserialize<'de> for AdaTokenType
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<AdaTokenType> for AdaElementType
impl From<AdaTokenType> for AdaElementType
Source§fn from(token_type: AdaTokenType) -> Self
fn from(token_type: AdaTokenType) -> Self
Converts to this type from the input type.
Source§impl Hash for AdaTokenType
impl Hash for AdaTokenType
Source§impl Ord for AdaTokenType
impl Ord for AdaTokenType
Source§fn cmp(&self, other: &AdaTokenType) -> Ordering
fn cmp(&self, other: &AdaTokenType) -> 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 AdaTokenType
impl PartialEq for AdaTokenType
Source§impl PartialOrd for AdaTokenType
impl PartialOrd for AdaTokenType
Source§impl Serialize for AdaTokenType
impl Serialize for AdaTokenType
Source§impl TokenType for AdaTokenType
impl TokenType for AdaTokenType
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_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_error(&self) -> bool
fn is_error(&self) -> bool
Returns true if this token represents an error condition. 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_ignored(&self) -> bool
fn is_ignored(&self) -> bool
Returns true if this token represents trivia (whitespace, comments, etc.). 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 AdaTokenType
impl Eq for AdaTokenType
impl StructuralPartialEq for AdaTokenType
Auto Trait Implementations§
impl Freeze for AdaTokenType
impl RefUnwindSafe for AdaTokenType
impl Send for AdaTokenType
impl Sync for AdaTokenType
impl Unpin for AdaTokenType
impl UnwindSafe for AdaTokenType
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