The upstream TCL parser is split into 3 parts: 1. The parser of the TCL language: https://github.com/universal-ctags/ctags/blob/master/parsers/tcl.c 2. The parser of TCLOO (the "current" object-oriented extension): https://github.com/universal-ctags/ctags/blob/master/parsers/tcloo.c 3. The parser of ITCL ("legacy" object-oriented extension): https://github.com/universal-ctags/ctags/blob/master/parsers/itcl.c
One can use the combo of 1+2 or 1+3 but it's not possible to use 1+2+3. uctags distinguishes which parser to use based on the file extension ("tcl" vs "itcl"). Our current parser generates tags both for ITCL and TCLOO. The question now is what to do: 1. Keep our parser (it doesn't seem to be so advanced like the upstream parser which is token-based and it means maintaining it by ourselves). 2. Use one of the combos TCLOO+TCL or ITCL+TCL and sacrifice the other OO extension (not sure which one would be better to use, I'm not a TCL user). 3. Introduce a new filetype so there will be "tcl" (which would be TCLOO+TCL) and "itcl" (which would be ITCL+TCL).
To reduce the amount of code we have to maintain, I personally would prefer (2) or (3). What do you think?
Personally I would say 2. with tcloo which "As of Tcl 8.6, is part of the core distribution.".
If TCLists needed itcl or other they could add a new filetype.
Just to clarify, I don't want to add this parser right now, will do it (together with the remaining parsers) only after the current parser PRs are merged (after which I plan to improve the symbol tree mapping).
Full agree with @elextr.
See #3157, closing.
Closed #3103.
github-comments@lists.geany.org