Branch: refs/heads/master Author: Colomban Wendling ban@herbesfolles.org Committer: Colomban Wendling ban@herbesfolles.org Date: Fri, 19 Oct 2012 19:39:38 Commit: f04df056cdd96be7c3319993d71b8dc36fdd397c https://github.com/geany/geany/commit/f04df056cdd96be7c3319993d71b8dc36fdd39...
Log Message: ----------- Fix parsing of C++11 final classes
Closes #3577559.
Modified Paths: -------------- tagmanager/ctags/c.c
Modified: tagmanager/ctags/c.c 9 files changed, 8 insertions(+), 1 deletions(-) =================================================================== @@ -423,7 +423,7 @@ { "extends", KEYWORD_EXTENDS, { 0, 0, 0, 1, 1, 0, 0 } }, { "extern", KEYWORD_EXTERN, { 1, 1, 1, 0, 1, 1, 0 } }, { "extern", KEYWORD_NAMESPACE, { 0, 0, 0, 0, 0, 0, 1 } }, /* parse block */ - { "final", KEYWORD_FINAL, { 0, 0, 0, 1, 0, 0, 1 } }, + { "final", KEYWORD_FINAL, { 0, 1, 0, 1, 0, 0, 1 } }, { "finally", KEYWORD_FINALLY, { 0, 0, 0, 0, 0, 1, 1 } }, { "float", KEYWORD_FLOAT, { 1, 1, 1, 1, 0, 1, 1 } }, { "for", KEYWORD_FOR, { 1, 1, 1, 1, 0, 1, 1 } }, @@ -2955,6 +2955,13 @@ static void tagCheck (statementInfo *const st) } } } + /* C++ 11 allows class <name> final { ... } */ + else if (isLanguage (Lang_cpp) && isType (prev, TOKEN_KEYWORD) && + prev->keyword == KEYWORD_FINAL && isType(prev2, TOKEN_NAME)) + { + name_token = (tokenInfo *)prev2; + copyToken (st->blockName, name_token); + } else if (isLanguage (Lang_csharp)) makeTag (prev, st, FALSE, TAG_PROPERTY); else
-------------- This E-Mail was brought to you by github_commit_mail.py (Source: TBD).