Sha256: 5866efe56eb782974c3eec5aabc2b728ee348a33c0d278770878cba5df334219
Contents?: true
Size: 1.85 KB
Versions: 50
Compression:
Stored size: 1.85 KB
Contents
# encoding: UTF-8 grammar ScientificNameCanonical include ScientificNameDirty rule root multinomial_with_garbage { def hybrid false end def details [super] end def parser_run 3 end } / uninomial_with_garbage { def hybrid false end def details [super] end def parser_run 3 end } end rule multinomial_with_garbage a:genus space b:infragenus space c:species garbage { def value a.value + " " + b.value + " " + c.value end def canonical a.canonical + " " + b.canonical + " " + c.canonical end def pos a.pos.merge(b.pos).merge(c.pos) end def details a.details.merge(b.details).merge(c.details) end } / a:genus space b:infragenus garbage { def value a.value + " " + b.value end def canonical a.canonical + " " + b.canonical end def pos a.pos.merge(b.pos) end def details a.details.merge(b.details) end } / a:genus space b:species garbage { def value a.value + " " + b.value end def canonical a.canonical + " " + b.canonical end def pos a.pos.merge(b.pos) end def details a.details.merge(b.details) end } end rule uninomial_with_garbage a:uninomial_string b:garbage { def value a.value end def canonical a.canonical end def pos a.pos end def details {:uninomial => a.details[:uninomial]} end } end rule garbage space (["',.]) space [^щ]* / space_hard [^ш]+ end end
Version data entries
50 entries across 50 versions & 2 rubygems