[TxMt] C functions not getting tagged correctly?
Matt Fago
fago at earthlink.net
Sun Oct 28 19:17:47 UTC 2007
On Oct 24, 2007, at 9:52 PM, Allan Odgaard wrote:
>
> The WIP C/C++ grammar is matching the full structure of your source
> code, there are 3 “concerns”:
>
> 1. It is more fragile (since an unforeseen or wrongly matched
> structure can throw it off).
> 2. It is somewhat slower than the regular grammar.
> 3. It doesn’t have as good support for the #if 0/1 … #else …
> #endif as the original grammar (since that structure is orthogonal
> with the structure of the actual C/C++ code).
>
> Number 1 just means it needs testing to the point where I am
> confident it works :)
>
> As for #2 and #3, for #2 we can only wait for TM 2.0 to really get
> that addressed and #3 either requires a lot of duplication in the
> grammar or also that we wait for TM 2.0 -- but as there is no ETA
> on TM 2.0, the question is if the demand for the improvements
> outweigh the tradeoffs, we haven’t really decided that, in the end
> I guess it is my call, and I am thinking we should make it trunk
> maybe in 1-2 months.
As a comment on the WIP C syntax: it seems to mark declarations as
well as definitions as functions. Not as big of a deal as missing
definitions, but probably not ultimately desirable. E.g.:
int testfn(int a);
int testfn(int a) {
...
}
leads to two "testfn" listings in the symbol menu. This may occur
when one has static functions, etc.
Thanks,
Matt
More information about the textmate
mailing list