SF.net SVN: geany:[4962] trunk

eht16 at users.sourceforge.net eht16 at xxxxx
Sun May 30 17:48:08 UTC 2010


Revision: 4962
          http://geany.svn.sourceforge.net/geany/?rev=4962&view=rev
Author:   eht16
Date:     2010-05-30 17:48:08 +0000 (Sun, 30 May 2010)

Log Message:
-----------
Fix parsing of C++ classes contain attributes with bitfields (patch by Lex Trotman, thanks).

Modified Paths:
--------------
    trunk/ChangeLog
    trunk/tagmanager/c.c

Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog	2010-05-30 17:47:54 UTC (rev 4961)
+++ trunk/ChangeLog	2010-05-30 17:48:08 UTC (rev 4962)
@@ -2,6 +2,9 @@
 
  * tagmanager/sort.c:
    Replace free() by g_free() (patch by Daniel Marjamaki, thanks).
+ * tagmanager/c.c:
+   Fix parsing of C++ classes contain attributes with bitfields
+   (patch by Lex Trotman, thanks).
 
 
 2010-05-29  Enrico Tröger  <enrico(dot)troeger(at)uvena(dot)de>

Modified: trunk/tagmanager/c.c
===================================================================
--- trunk/tagmanager/c.c	2010-05-30 17:47:54 UTC (rev 4961)
+++ trunk/tagmanager/c.c	2010-05-30 17:48:08 UTC (rev 4962)
@@ -2555,13 +2555,15 @@
 	else
 	{
 		cppUngetc (c);
-		if (((isLanguage (Lang_cpp) || isLanguage (Lang_csharp) || isLanguage (Lang_vala))  &&
+		if ((((isLanguage (Lang_cpp) &&
+				(st->declaration == DECL_CLASS || st->declaration == DECL_STRUCT)) ||
+		    isLanguage (Lang_csharp) || isLanguage (Lang_vala))  &&
 			inheritingDeclaration (st->declaration)) ||
 			isLanguage (Lang_d))
 		{
 			readParents (st, ':');
 		}
-		else if (parentDecl (st) == DECL_STRUCT)
+		else if (parentDecl (st) == DECL_STRUCT || parentDecl (st) == DECL_CLASS)
 		{
 			c = skipToOneOf (",;");
 			if (c == ',')


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



More information about the Commits mailing list