Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Lexer ¶
type Lexer struct {
// contains filtered or unexported fields
}
Lexer is a lexer for format strings.
func (*Lexer) Lex ¶
Lex lexes the stream. Does nothing if the receiver or the stream are nil.
Returns:
- error: An error if the stream could not be lexed.
NOTES:
- Remember to call Reset() after the stream has been lexed to avoid previous tokens being left in the stream.
func (*Lexer) SetInputStream ¶
func (l *Lexer) SetInputStream(stream io.RuneScanner)
SetInputStream sets the stream to lex. Does nothing if the receiver is nil.
Parameters:
- stream: The stream to lex.
Click to show internal directories.
Click to hide internal directories.