Enum member isSaveableLexer
Checks whether its argument is a saveable lexer.
A saveable lexer is a lexer enhanced with a save
method analogous to the save
method of ForwardRange
s.
Declaration
enum isSaveableLexer(L) = isLexer!L && is(typeof((inout int = 0)
{
L lexer1;
L lexer2 = lexer1 .save();
}
));
Parameters
Name | Description |
---|---|
L | the type to be tested |
Returns
true
if L is a lexer (as specified by isLexer
) and also supports the save
method as specified here; false
otherwise
Specification
The type shall support at least:
- all methods and aliases specified by
isLexer
L save()
: returns an independent copy of the current lexer; the copy must start at the position the original lexer was when this method was called; the two copies shall be independent, in that advancing one does not advance the other.
Authors
Lodovico Giaretta
Copyright
Copyright Lodovico Giaretta 2016 --