ziglang / sublime-zig-language

Zig language support for Sublime Text
MIT License
85 stars 25 forks source link

Remove look behind to use the fast version of SublimeText indexer #45

Closed gwenzek closed 3 years ago

gwenzek commented 4 years ago

Overview

Sublime Text has its own parser/tokenizer. It has an old version that handle look-behind in regexes, and a faster on that disallow them. I removed the look-behind in this PR trying to make as few changes as possible to the syntax. This is a follow up on #41.

Simple benchmark

I ran Syntax Tests - Performance on 2000 lines of Zig code, made from custom code and hash_map.zig from the std lib.

How to review this PR

gwenzek commented 3 years ago

@emekoi Can I get a review on this please ?

emekoi commented 3 years ago

sorry about taking so long to get back to you, i was extremely busy with school but i should be able to review and merge this by friday, if not tomorrow/tonight.

emekoi commented 3 years ago

thanks for taking the time to do this and being so patient with me.

gwenzek commented 3 years ago

Thanks for the review, and maintaining this package. I'll be sure to stick around in case people find a bug or if there is subtle behavior change that trip up users.