ml_switcheroo.compiler.frontends.sass.tokens¶
SASS Tokenizer Definition.
Provides a Regex-based Lexer (SassLexer) that decomposes raw NVIDIA SASS assembly strings into a stream of typed Token objects.
Classes¶
Enumeration of valid SASS token types. |
|
Represents a lexical unit. |
|
Regex-based Lexer for NVIDIA SASS assembly. |
Module Contents¶
- class ml_switcheroo.compiler.frontends.sass.tokens.TokenType(*args, **kwds)[source]¶
Bases:
enum.EnumEnumeration of valid SASS token types.
- LABEL_DEF¶
- DIRECTIVE¶
- COMMENT¶
- SEMICOLON¶
- COMMA¶
- PREDICATE¶
- REGISTER¶
- MEMORY¶
- IMMEDIATE¶
- IDENTIFIER¶
- class ml_switcheroo.compiler.frontends.sass.tokens.Token[source]¶
Represents a lexical unit.
- value¶
The raw string content.
- Type:
str
- line¶
Line number in source (1-based).
- Type:
int
- column¶
Column number in source (1-based).
- Type:
int
- value: str¶
- line: int¶
- column: int¶