Add COM object recognition #234
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi Everyone,
This is the Pull Request that I mentioned in Issue #232 . This will fix (I believe) the issues mentioned in the Feature Request, namely COM Objects ending in brackets mistakenly being recognized as user functions, due to the way the TM language file is currently set up.
The second addition I have in my changes is to add a separate recognition for COM Objects, and consequently, also recognition for Map key access using dot notation. This will match Scite’s behaviour where COM Objects and Map keys using Dot notation will be colored the same. The present behaviour is all COM Objects are not tokenized as such.
I have applied a token name that I thought would be fitting, but of course, you would know better whether this will be appropriate or not.
The only other thing, which I brought up in the Feature Request is that currently user Functions without parenthesis after them, are not tokenized as functions. As my example showed, $MyFunc = _Func123 would not be tokenized. My changes currently do NOT fix this. Most likely if I were to do so, I wold just make the Parenthesis search optional with a quantifier. Perhaps someone has a more elegant solution than that.
Best regards,
Donny