#include <SkSLLexer.h>
Definition at line 123 of file SkSLLexer.h.
◆ getCheckpoint()
◆ next()
Token SkSL::Lexer::next |
( |
| ) |
|
Definition at line 800 of file SkSLLexer.cpp.
800 {
801
802
803
804
805
806 int32_t startOffset = fOffset;
808 for (;;) {
809 if (fOffset >= (int32_t)fText.length()) {
810 if (startOffset == (int32_t)fText.length() ||
kAccepts[
state] == 255) {
812 }
813 break;
814 }
815 uint8_t c = (uint8_t)(fText[fOffset] - 9);
816 if (c >= 118) {
818 }
820 if (!newState) {
821 break;
822 }
824 ++fOffset;
825 }
827 return Token(kind, startOffset, fOffset - startOffset);
828}
static const uint8_t kAccepts[427]
static State get_transition(uint8_t transition, State state)
static constexpr uint8_t kInvalidChar
static constexpr uint8_t kMappings[118]
◆ rewindToCheckpoint()
void SkSL::Lexer::rewindToCheckpoint |
( |
Checkpoint |
checkpoint | ) |
|
|
inline |
Definition at line 138 of file SkSLLexer.h.
138{ fOffset = checkpoint.fOffset; }
◆ start()
void SkSL::Lexer::start |
( |
std::string_view |
text | ) |
|
|
inline |
Definition at line 125 of file SkSLLexer.h.
125 {
127 fOffset = 0;
128 }
The documentation for this class was generated from the following files: