no-context / moo

Optimised tokenizer/lexer generator! 🐄 Uses /y for performance. Moo.
BSD 3-Clause "New" or "Revised" License
821 stars 65 forks source link

Bugs in the impl #72

Closed ghost closed 7 years ago

ghost commented 7 years ago

https://github.com/no-context/moo/blob/master/moo.js#L258

throw new Error('keyword type must be string: ' + name)

The identifier name doesn't exist.

Also, https://github.com/no-context/moo/blob/master/moo.js#L395, where variable nl depends on a variable hoisted from a block above. Not a bug per se, but truly ugly.

tjvr commented 7 years ago

The identifier name doesn't exist.

Thanks. Fixed in fd9210c.

truly ugly.

There's really no need to be rude.

ghost commented 7 years ago

@tjvr not rude at all, just an observation

nathan commented 7 years ago

@notsonotso

not rude at all, just an observation

You called someone else's work "truly ugly":

ugly |ˈəɡli|

unpleasant or repulsive, especially in appearance

That is rude. If you meant "error-prone," stop being vitriolic and just say "error-prone".