The result of the function TSynCustomHighlighter.GetTokenKind seems to be totally unsused.
I found it used it 2 or 3 places. But that aside many functions are from the original SynEdit project. The Highlighters had a big refactor, but there was no need to remove this.
As for GetTokenKind in GetHighlighterAttriAtRowColEx:
This may be a different story. Probably that code was refactored at some stage too. SVN history may tell....
GetHighlighterAttriAtRowColEx is a puplic function. That means it can be used by user code, and functionality can not be removed.
The only way would be to make a copy of it, and use the copy if less info is needed. That comes with the burden of more maintenance. The function is called ONCE when you get at a bracket or quote. To save that one single call, I would not create copy and paste duplicate code.
Actually FindMatchingBracketLogical should not call GetHighlighterAttriAtRowColEx at all. "IsContextBracket" should be refactored, so it could return the value, and be used to get token kind.
Also:
TmpAttr is the value from Highlighter.GetTokenAttribute, not GetTokenKind.