AdamNiederer / ng2-mode

Angular Support for Emacs
GNU General Public License v3.0
73 stars 11 forks source link

Fixed endless loop in syntax highlighting for lambdas #25

Closed LlinksRechts closed 3 years ago

LlinksRechts commented 3 years ago

Fixes #21

Syntax highlighting in lambda signatures incorrectly advances the cursor position if the given return type contains generic types (ie. a >). In this case, the pointer gets stuck on this character, and loops indefinitely. This fix advances over any > that may occur after (=at the end of) the signature. The problem could probably be fixed by adjusting some regexes, but this seems to work, and shouldn't introduce any other problems as far as I'm aware.

AdamNiederer commented 3 years ago

Thanks a bunch!