In typescript (or javascript as well), regexp is part of the language and can be expressed like so
And we have the following rules to match it:
- constant: "/[^*]([^/]|(\\\\/))*[^\\\\]/[gim]*"
If you have the following
//My use case:
vec2.set(outVec, width / 2.0, height / 2.0);
//Or simply
const abc = 10 / 5 / 2;
Looks like this
Funny enough, javascript doesn't have this problem since the line is commented out. Due to issue #901
But then it got a different issue, somehow (issue #2820), which got fixed later.
A proper fix (if we want to highlight it) requires lookahead as mentioned by @zyedidia in #901 ,unless there's a way to specify a pattern that excludes that type.
@JoeKar, any thoughts?
In typescript (or javascript as well), regexp is part of the language and can be expressed like so
And we have the following rules to match it:
If you have the following
Looks like this
Funny enough, javascript doesn't have this problem since the line is commented out. Due to issue #901
But then it got a different issue, somehow (issue #2820), which got fixed later.
A proper fix (if we want to highlight it) requires lookahead as mentioned by @zyedidia in #901 ,unless there's a way to specify a pattern that excludes that type.
@JoeKar, any thoughts?