class Gettext::PluralForm::Scanner
- Gettext::PluralForm::Scanner
- Lens::Base::Lexer(Gettext::PluralForm::Token)
- Reference
- Object
Overview
A scanner to tokenize a subset of C's grammar
Based on https://www.craftinginterpreters.com/scanning.html
Defined in:
backend/gettext/plural-forms/lexer.crConstructors
-
.new(source : String)
Creates a new scanner instance with the given source
Instance methods inherited from class Lens::Base::Lexer(Gettext::PluralForm::Token)
next
next,
scan
scan
Constructor methods inherited from class Lens::Base::Lexer(Gettext::PluralForm::Token)
new(source : String)
new
Constructor Detail
def self.new(source : String)
#
Creates a new scanner instance with the given source
plural_form_scanner = Gettext::PluralForm::Scanner.new("nplurals=2; plural=(n > 1);")