[SVN] Revision 2151 (C)
Allan Odgaard
throw-away-1 at macromates.com
Tue Nov 15 00:39:27 UTC 2005
• removed the preference and instead named the function name capture entity.name.function.c
• allow &, * and > to be the character in front of the function name, for cases like:
char* function ()
std::vector<char> function ()
std::string& function ()
• reject cases where the word in front of the function name is new, else or &&, for these cases:
constructor (arg) : member(new something())
else if(something)
if(foo && bar())
• made the rule use a begin up until '(' and end that matched ')', so that we can do include = "$base" for the stuff between (so arguments get proper markup)
• allow optional const after function for C++ methods:
void member_function () cosnt
• allow :: in name, again for member functions:
void my_class::member ()
Currently there's a false positive when doing something like (because I added * as valid in front of the function name):
if(32 == foo * sizeof(b))
And it doesn't catch any of the C++ special stuff (constructor/destructor, overloaded operators, and user conversion operators) -- probably it'd be best to keep that in the C++ syntax (if it needs to be matched). Some of the above could also be moved to there.
Changed:
D trunk/Bundles/C.tmbundle/Preferences/Symbol List: functions.plist
U trunk/Bundles/C.tmbundle/Syntaxes/C.plist
More information about the textmate-dev
mailing list