anjuta r4549 - in trunk: . plugins/symbol-db



Author: mcora
Date: Wed Jan  7 18:15:46 2009
New Revision: 4549
URL: http://svn.gnome.org/viewvc/anjuta?rev=4549&view=rev

Log:
	* plugins/symbol-db/plugin.c (goto_file_tag):
	* plugins/symbol-db/symbol-db-engine-core.c
	(sdb_engine_insert_dyn_query_node_by_id):
	fixed #566691 â Goto declaration nor goto definition work with macros

Modified:
   trunk/ChangeLog
   trunk/plugins/symbol-db/plugin.c
   trunk/plugins/symbol-db/symbol-db-engine-core.c

Modified: trunk/plugins/symbol-db/plugin.c
==============================================================================
--- trunk/plugins/symbol-db/plugin.c	(original)
+++ trunk/plugins/symbol-db/plugin.c	Wed Jan  7 18:15:46 2009
@@ -136,17 +136,9 @@
 		symbol_kind = symbol_db_engine_iterator_node_get_symbol_extra_string (
 					iter_node, SYMINFO_KIND);				
 		
-		if (prefer_definition == FALSE && g_strcmp0 (symbol_kind, "prototype") == 0)
-		{
-			gint line = 
-				symbol_db_engine_iterator_node_get_symbol_file_pos (iter_node);
-			const gchar* file = 
-				symbol_db_engine_iterator_node_get_symbol_extra_string (iter_node,
-													SYMINFO_FILE_PATH);
-			goto_file_line (ANJUTA_PLUGIN (sdb_plugin), file, line);
-			break;
-		}
-		else if (prefer_definition == TRUE && g_strcmp0 (symbol_kind, "function") == 0)
+		if ((prefer_definition == FALSE && g_strcmp0 (symbol_kind, "prototype") == 0) ||
+			(prefer_definition == TRUE && g_strcmp0 (symbol_kind, "function") == 0) ||
+			(prefer_definition == TRUE && g_strcmp0 (symbol_kind, "macro") == 0))
 		{
 			gint line = 
 				symbol_db_engine_iterator_node_get_symbol_file_pos (iter_node);

Modified: trunk/plugins/symbol-db/symbol-db-engine-core.c
==============================================================================
--- trunk/plugins/symbol-db/symbol-db-engine-core.c	(original)
+++ trunk/plugins/symbol-db/symbol-db-engine-core.c	Wed Jan  7 18:15:46 2009
@@ -528,6 +528,7 @@
 		dyn_node = g_new0 (DynChildQueryNode, 1);
 		
 		/* create a new GdaStatement */
+		dyn_node->plist = NULL;
 		dyn_node->stmt =
 			gda_sql_parser_parse_string (priv->sql_parser, sql, NULL, 
 										 NULL);
@@ -546,7 +547,7 @@
 		/* return it */
 		return dyn_node;
 	}
-	else 
+	else
 	{
 		/* ok, this is a slightly more complex case */
 		GTree *child_gtree;
@@ -560,6 +561,7 @@
 		dyn_node = g_new0 (DynChildQueryNode, 1);
 		
 		/* create a new GdaStatement */
+		dyn_node->plist = NULL;
 		dyn_node->stmt =
 			gda_sql_parser_parse_string (priv->sql_parser, sql, NULL, 
 										 NULL);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]