tracker-0.16.2/src/libtracker-data/tracker-sparql-pattern.c

Location Tool Test ID Function Issue
tracker-sparql-pattern.c:799:7 clang-analyzer Value stored to 'prop_collection_length1' is never read
tracker-sparql-pattern.c:1139:8 clang-analyzer Value stored to 'prop_collection_length1' is never read
tracker-sparql-pattern.c:1325:7 clang-analyzer Value stored to 'prop_collection_length1' is never read
tracker-sparql-pattern.c:1393:0 cppcheck syntaxError syntax error
tracker-sparql-pattern.c:2636:11 gcc unused-but-set-variable tracker_sparql_pattern_translate_select variable '_tmp84__length1' set but not used
tracker-sparql-pattern.c:2727:6 clang-analyzer Value stored to '_tmp78_' is never read
tracker-sparql-pattern.c:2729:6 clang-analyzer Value stored to '_tmp78__length1' is never read
tracker-sparql-pattern.c:2743:6 clang-analyzer Value stored to '_tmp84_' is never read
tracker-sparql-pattern.c:2745:6 clang-analyzer Value stored to '_tmp84__length1' is never read
tracker-sparql-pattern.c:2876:6 clang-analyzer Value stored to '_tmp102_' is never read
tracker-sparql-pattern.c:2878:6 clang-analyzer Value stored to '_tmp102__length1' is never read
tracker-sparql-pattern.c:4343:4 clang-analyzer Value stored to 'fts_var_collection_length1' is never read
tracker-sparql-pattern.c:7950:8 gcc unused-variable tracker_sparql_pattern_is_subclass unused variable '_superclass_collection_size_'
tracker-sparql-pattern.c:7960:3 clang-analyzer Value stored to 'superclass_collection_length1' is never read
tracker-sparql-pattern.c:9057:2 gcc _tracker_sparql_variable_hash_ghash_func passing argument 1 of 'tracker_sparql_variable_hash' discards 'const' qualifier from pointer target type [enabled by default]
tracker-sparql-pattern.c:9066:2 gcc _tracker_sparql_variable_equal_gequal_func passing argument 1 of 'tracker_sparql_variable_equal' discards 'const' qualifier from pointer target type [enabled by default]
tracker-sparql-pattern.c:10932:12 gcc unused-but-set-variable tracker_sparql_pattern_translate_group_graph_pattern variable '_tmp273__length1' set but not used
tracker-sparql-pattern.c:10940:7 clang-analyzer Value stored to '_tmp273_' is never read
tracker-sparql-pattern.c:10942:7 clang-analyzer Value stored to '_tmp273__length1' is never read
tracker-sparql-pattern.c:11161:2 clang-analyzer Value stored to '_tmp287_' is never read
tracker-sparql-pattern.c:11189:4 clang-analyzer Value stored to 'filter_location_collection_length1' is never read
tracker-sparql-pattern.c:11193:27 clang-analyzer Value stored to 'filter_location' during its initialization is never read
tracker-sparql-pattern.c:11405:9 gcc unused-but-set-variable tracker_sparql_pattern_translate_group_or_union_graph_pattern variable '_tmp15__length1' set but not used
tracker-sparql-pattern.c:11467:4 clang-analyzer Value stored to '_tmp9_' is never read
tracker-sparql-pattern.c:11469:4 clang-analyzer Value stored to '_tmp9__length1' is never read
tracker-sparql-pattern.c:11518:4 clang-analyzer Value stored to '_tmp15_' is never read
tracker-sparql-pattern.c:11520:4 clang-analyzer Value stored to '_tmp15__length1' is never read
tracker-sparql-pattern.c:11527:2 clang-analyzer Value stored to '_tmp16_' is never read
tracker-sparql-pattern.c:11550:4 clang-analyzer Value stored to 'sub_context_collection_length1' is never read
tracker-sparql-pattern.c:11610:10 clang-analyzer Value stored to '_tmp25_' is never read
tracker-sparql-pattern.c:11612:10 clang-analyzer Value stored to '_tmp25__length1' is never read
tracker-sparql-pattern.c:11710:6 clang-analyzer Value stored to '_tmp40_' is never read
tracker-sparql-pattern.c:11752:7 clang-analyzer Value stored to 'v_collection_length1' is never read
tracker-sparql-pattern.c:11778:9 clang-analyzer Value stored to '_tmp47__length1' is never read
tracker-sparql-pattern.c:11832:6 clang-analyzer Value stored to '_tmp63__length1' is never read
tracker-sparql-pattern.c:11873:3 clang-analyzer Value stored to '_tmp73__length1' is never read
tracker-sparql-pattern.c:13140:13 gcc unused-variable tracker_sparql_pattern_parse_object unused variable '_cl_collection_size_'
tracker-sparql-pattern.c:13150:8 clang-analyzer Value stored to 'cl_collection_length1' is never read
tracker-sparql-pattern.c:15056:25 gcc unused-but-set-variable _vala_tracker_sparql_pattern_get_property variable 'self' set but not used
tracker-sparql-pattern.c:15062:2 clang-analyzer Value stored to 'self' is never read
tracker-sparql-pattern.c:15072:25 gcc unused-but-set-variable _vala_tracker_sparql_pattern_set_property variable 'self' set but not used
tracker-sparql-pattern.c:15078:2 clang-analyzer Value stored to 'self' is never read
    1 /* tracker-sparql-pattern.c generated by valac 0.18.1, the Vala compiler
    2  * generated from tracker-sparql-pattern.vala, do not modify */
    3 
    4 /*
    5  * Copyright (C) 2008-2010, Nokia
    6  *
    7  * This library is free software; you can redistribute it and/or
    8  * modify it under the terms of the GNU Lesser General Public
    9  * License as published by the Free Software Foundation; either
   10  * version 2.1 of the License, or (at your option) any later version.
   11  *
   12  * This library is distributed in the hope that it will be useful,
   13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
   14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
   15  * Lesser General Public License for more details.
   16  *
   17  * You should have received a copy of the GNU Lesser General Public
   18  * License along with this library; if not, write to the
   19  * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
   20  * Boston, MA  02110-1301, USA.
   21  */
   22 
   23 #include <glib.h>
   24 #include <glib-object.h>
   25 #include <stdlib.h>
   26 #include <string.h>
   27 #include "libtracker-data/tracker-class.h"
   28 #include "libtracker-sparql/tracker-sparql.h"
   29 #include "libtracker-data/tracker-data-query.h"
   30 #include "libtracker-data/tracker-data-update.h"
   31 #include "libtracker-data/tracker-data-backup.h"
   32 #include "libtracker-data/tracker-db-interface.h"
   33 #include "libtracker-data/tracker-db-manager.h"
   34 #include "libtracker-data/tracker-ontologies.h"
   35 #include "libtracker-data/tracker-property.h"
   36 
   37 
   38 #define TRACKER_SPARQL_TYPE_PREDICATE_VARIABLE (tracker_sparql_predicate_variable_get_type ())
   39 #define TRACKER_SPARQL_PREDICATE_VARIABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_PREDICATE_VARIABLE, TrackerSparqlPredicateVariable))
   40 #define TRACKER_SPARQL_PREDICATE_VARIABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_PREDICATE_VARIABLE, TrackerSparqlPredicateVariableClass))
   41 #define TRACKER_SPARQL_IS_PREDICATE_VARIABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_PREDICATE_VARIABLE))
   42 #define TRACKER_SPARQL_IS_PREDICATE_VARIABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_PREDICATE_VARIABLE))
   43 #define TRACKER_SPARQL_PREDICATE_VARIABLE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_PREDICATE_VARIABLE, TrackerSparqlPredicateVariableClass))
   44 
   45 typedef struct _TrackerSparqlPredicateVariable TrackerSparqlPredicateVariable;
   46 typedef struct _TrackerSparqlPredicateVariableClass TrackerSparqlPredicateVariableClass;
   47 typedef struct _TrackerSparqlPredicateVariablePrivate TrackerSparqlPredicateVariablePrivate;
   48 #define _g_free0(var) (var = (g_free (var), NULL))
   49 #define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))
   50 
   51 #define TRACKER_SPARQL_TYPE_QUERY (tracker_sparql_query_get_type ())
   52 #define TRACKER_SPARQL_QUERY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_QUERY, TrackerSparqlQuery))
   53 #define TRACKER_SPARQL_QUERY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_QUERY, TrackerSparqlQueryClass))
   54 #define TRACKER_SPARQL_IS_QUERY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_QUERY))
   55 #define TRACKER_SPARQL_IS_QUERY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_QUERY))
   56 #define TRACKER_SPARQL_QUERY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_QUERY, TrackerSparqlQueryClass))
   57 
   58 typedef struct _TrackerSparqlQuery TrackerSparqlQuery;
   59 typedef struct _TrackerSparqlQueryClass TrackerSparqlQueryClass;
   60 #define _g_string_free0(var) ((var == NULL) ? NULL : (var = (g_string_free (var, TRUE), NULL)))
   61 
   62 #define TRACKER_SPARQL_TYPE_DATA_BINDING (tracker_sparql_data_binding_get_type ())
   63 #define TRACKER_SPARQL_DATA_BINDING(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_DATA_BINDING, TrackerSparqlDataBinding))
   64 #define TRACKER_SPARQL_DATA_BINDING_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_DATA_BINDING, TrackerSparqlDataBindingClass))
   65 #define TRACKER_SPARQL_IS_DATA_BINDING(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_DATA_BINDING))
   66 #define TRACKER_SPARQL_IS_DATA_BINDING_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_DATA_BINDING))
   67 #define TRACKER_SPARQL_DATA_BINDING_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_DATA_BINDING, TrackerSparqlDataBindingClass))
   68 
   69 typedef struct _TrackerSparqlDataBinding TrackerSparqlDataBinding;
   70 typedef struct _TrackerSparqlDataBindingClass TrackerSparqlDataBindingClass;
   71 
   72 #define TRACKER_SPARQL_TYPE_LITERAL_BINDING (tracker_sparql_literal_binding_get_type ())
   73 #define TRACKER_SPARQL_LITERAL_BINDING(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_LITERAL_BINDING, TrackerSparqlLiteralBinding))
   74 #define TRACKER_SPARQL_LITERAL_BINDING_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_LITERAL_BINDING, TrackerSparqlLiteralBindingClass))
   75 #define TRACKER_SPARQL_IS_LITERAL_BINDING(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_LITERAL_BINDING))
   76 #define TRACKER_SPARQL_IS_LITERAL_BINDING_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_LITERAL_BINDING))
   77 #define TRACKER_SPARQL_LITERAL_BINDING_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_LITERAL_BINDING, TrackerSparqlLiteralBindingClass))
   78 
   79 typedef struct _TrackerSparqlLiteralBinding TrackerSparqlLiteralBinding;
   80 typedef struct _TrackerSparqlLiteralBindingClass TrackerSparqlLiteralBindingClass;
   81 typedef struct _TrackerSparqlDataBindingPrivate TrackerSparqlDataBindingPrivate;
   82 
   83 #define TRACKER_SPARQL_TYPE_DATA_TABLE (tracker_sparql_data_table_get_type ())
   84 #define TRACKER_SPARQL_DATA_TABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_DATA_TABLE, TrackerSparqlDataTable))
   85 #define TRACKER_SPARQL_DATA_TABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_DATA_TABLE, TrackerSparqlDataTableClass))
   86 #define TRACKER_SPARQL_IS_DATA_TABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_DATA_TABLE))
   87 #define TRACKER_SPARQL_IS_DATA_TABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_DATA_TABLE))
   88 #define TRACKER_SPARQL_DATA_TABLE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_DATA_TABLE, TrackerSparqlDataTableClass))
   89 
   90 typedef struct _TrackerSparqlDataTable TrackerSparqlDataTable;
   91 typedef struct _TrackerSparqlDataTableClass TrackerSparqlDataTableClass;
   92 typedef struct _TrackerSparqlLiteralBindingPrivate TrackerSparqlLiteralBindingPrivate;
   93 typedef struct _TrackerSparqlQueryPrivate TrackerSparqlQueryPrivate;
   94 
   95 #define TRACKER_SPARQL_TYPE_EXPRESSION (tracker_sparql_expression_get_type ())
   96 #define TRACKER_SPARQL_EXPRESSION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_EXPRESSION, TrackerSparqlExpression))
   97 #define TRACKER_SPARQL_EXPRESSION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_EXPRESSION, TrackerSparqlExpressionClass))
   98 #define TRACKER_SPARQL_IS_EXPRESSION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_EXPRESSION))
   99 #define TRACKER_SPARQL_IS_EXPRESSION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_EXPRESSION))
  100 #define TRACKER_SPARQL_EXPRESSION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_EXPRESSION, TrackerSparqlExpressionClass))
  101 
  102 typedef struct _TrackerSparqlExpression TrackerSparqlExpression;
  103 typedef struct _TrackerSparqlExpressionClass TrackerSparqlExpressionClass;
  104 
  105 #define TRACKER_SPARQL_TYPE_PATTERN (tracker_sparql_pattern_get_type ())
  106 #define TRACKER_SPARQL_PATTERN(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_PATTERN, TrackerSparqlPattern))
  107 #define TRACKER_SPARQL_PATTERN_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_PATTERN, TrackerSparqlPatternClass))
  108 #define TRACKER_SPARQL_IS_PATTERN(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_PATTERN))
  109 #define TRACKER_SPARQL_IS_PATTERN_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_PATTERN))
  110 #define TRACKER_SPARQL_PATTERN_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_PATTERN, TrackerSparqlPatternClass))
  111 
  112 typedef struct _TrackerSparqlPattern TrackerSparqlPattern;
  113 typedef struct _TrackerSparqlPatternClass TrackerSparqlPatternClass;
  114 
  115 #define TRACKER_SPARQL_TYPE_CONTEXT (tracker_sparql_context_get_type ())
  116 #define TRACKER_SPARQL_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_CONTEXT, TrackerSparqlContext))
  117 #define TRACKER_SPARQL_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_CONTEXT, TrackerSparqlContextClass))
  118 #define TRACKER_SPARQL_IS_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_CONTEXT))
  119 #define TRACKER_SPARQL_IS_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_CONTEXT))
  120 #define TRACKER_SPARQL_CONTEXT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_CONTEXT, TrackerSparqlContextClass))
  121 
  122 typedef struct _TrackerSparqlContext TrackerSparqlContext;
  123 typedef struct _TrackerSparqlContextClass TrackerSparqlContextClass;
  124 #define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
  125 typedef struct _TrackerSparqlPatternPrivate TrackerSparqlPatternPrivate;
  126 
  127 #define TRACKER_SPARQL_TYPE_VARIABLE (tracker_sparql_variable_get_type ())
  128 #define TRACKER_SPARQL_VARIABLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_VARIABLE, TrackerSparqlVariable))
  129 #define TRACKER_SPARQL_VARIABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_VARIABLE, TrackerSparqlVariableClass))
  130 #define TRACKER_SPARQL_IS_VARIABLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_VARIABLE))
  131 #define TRACKER_SPARQL_IS_VARIABLE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_VARIABLE))
  132 #define TRACKER_SPARQL_VARIABLE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_VARIABLE, TrackerSparqlVariableClass))
  133 
  134 typedef struct _TrackerSparqlVariable TrackerSparqlVariable;
  135 typedef struct _TrackerSparqlVariableClass TrackerSparqlVariableClass;
  136 
  137 #define TRACKER_SPARQL_PATTERN_TYPE_TRIPLE_CONTEXT (tracker_sparql_pattern_triple_context_get_type ())
  138 #define TRACKER_SPARQL_PATTERN_TRIPLE_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_PATTERN_TYPE_TRIPLE_CONTEXT, TrackerSparqlPatternTripleContext))
  139 #define TRACKER_SPARQL_PATTERN_TRIPLE_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_PATTERN_TYPE_TRIPLE_CONTEXT, TrackerSparqlPatternTripleContextClass))
  140 #define TRACKER_SPARQL_PATTERN_IS_TRIPLE_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_PATTERN_TYPE_TRIPLE_CONTEXT))
  141 #define TRACKER_SPARQL_PATTERN_IS_TRIPLE_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_PATTERN_TYPE_TRIPLE_CONTEXT))
  142 #define TRACKER_SPARQL_PATTERN_TRIPLE_CONTEXT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_PATTERN_TYPE_TRIPLE_CONTEXT, TrackerSparqlPatternTripleContextClass))
  143 
  144 typedef struct _TrackerSparqlPatternTripleContext TrackerSparqlPatternTripleContext;
  145 typedef struct _TrackerSparqlPatternTripleContextClass TrackerSparqlPatternTripleContextClass;
  146 #define _tracker_sparql_context_unref0(var) ((var == NULL) ? NULL : (var = (tracker_sparql_context_unref (var), NULL)))
  147 
  148 #define TRACKER_TYPE_SPARQL_TOKEN_TYPE (tracker_sparql_token_type_get_type ())
  149 
  150 #define TRACKER_TYPE_SOURCE_LOCATION (tracker_source_location_get_type ())
  151 typedef struct _TrackerSourceLocation TrackerSourceLocation;
  152 
  153 #define TRACKER_SPARQL_TYPE_SELECT_CONTEXT (tracker_sparql_select_context_get_type ())
  154 #define TRACKER_SPARQL_SELECT_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_SELECT_CONTEXT, TrackerSparqlSelectContext))
  155 #define TRACKER_SPARQL_SELECT_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_SELECT_CONTEXT, TrackerSparqlSelectContextClass))
  156 #define TRACKER_SPARQL_IS_SELECT_CONTEXT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_SELECT_CONTEXT))
  157 #define TRACKER_SPARQL_IS_SELECT_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_SELECT_CONTEXT))
  158 #define TRACKER_SPARQL_SELECT_CONTEXT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_SELECT_CONTEXT, TrackerSparqlSelectContextClass))
  159 
  160 typedef struct _TrackerSparqlSelectContext TrackerSparqlSelectContext;
  161 typedef struct _TrackerSparqlSelectContextClass TrackerSparqlSelectContextClass;
  162 #define __g_list_free__g_object_unref0_0(var) ((var == NULL) ? NULL : (var = (_g_list_free__g_object_unref0_ (var), NULL)))
  163 typedef struct _TrackerSparqlContextPrivate TrackerSparqlContextPrivate;
  164 
  165 #define TRACKER_SPARQL_TYPE_VARIABLE_STATE (tracker_sparql_variable_state_get_type ())
  166 #define _g_list_free0(var) ((var == NULL) ? NULL : (var = (g_list_free (var), NULL)))
  167 typedef struct _TrackerSparqlVariablePrivate TrackerSparqlVariablePrivate;
  168 
  169 #define TRACKER_SPARQL_TYPE_VARIABLE_BINDING (tracker_sparql_variable_binding_get_type ())
  170 #define TRACKER_SPARQL_VARIABLE_BINDING(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_VARIABLE_BINDING, TrackerSparqlVariableBinding))
  171 #define TRACKER_SPARQL_VARIABLE_BINDING_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_VARIABLE_BINDING, TrackerSparqlVariableBindingClass))
  172 #define TRACKER_SPARQL_IS_VARIABLE_BINDING(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_VARIABLE_BINDING))
  173 #define TRACKER_SPARQL_IS_VARIABLE_BINDING_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_VARIABLE_BINDING))
  174 #define TRACKER_SPARQL_VARIABLE_BINDING_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_VARIABLE_BINDING, TrackerSparqlVariableBindingClass))
  175 
  176 typedef struct _TrackerSparqlVariableBinding TrackerSparqlVariableBinding;
  177 typedef struct _TrackerSparqlVariableBindingClass TrackerSparqlVariableBindingClass;
  178 typedef struct _TrackerSparqlSelectContextPrivate TrackerSparqlSelectContextPrivate;
  179 typedef struct _TrackerSparqlPatternTripleContextPrivate TrackerSparqlPatternTripleContextPrivate;
  180 
  181 #define TRACKER_SPARQL_TYPE_VARIABLE_BINDING_LIST (tracker_sparql_variable_binding_list_get_type ())
  182 #define TRACKER_SPARQL_VARIABLE_BINDING_LIST(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TRACKER_SPARQL_TYPE_VARIABLE_BINDING_LIST, TrackerSparqlVariableBindingList))
  183 #define TRACKER_SPARQL_VARIABLE_BINDING_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TRACKER_SPARQL_TYPE_VARIABLE_BINDING_LIST, TrackerSparqlVariableBindingListClass))
  184 #define TRACKER_SPARQL_IS_VARIABLE_BINDING_LIST(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TRACKER_SPARQL_TYPE_VARIABLE_BINDING_LIST))
  185 #define TRACKER_SPARQL_IS_VARIABLE_BINDING_LIST_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TRACKER_SPARQL_TYPE_VARIABLE_BINDING_LIST))
  186 #define TRACKER_SPARQL_VARIABLE_BINDING_LIST_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TRACKER_SPARQL_TYPE_VARIABLE_BINDING_LIST, TrackerSparqlVariableBindingListClass))
  187 
  188 typedef struct _TrackerSparqlVariableBindingList TrackerSparqlVariableBindingList;
  189 typedef struct _TrackerSparqlVariableBindingListClass TrackerSparqlVariableBindingListClass;
  190 typedef struct _TrackerSparqlDataTablePrivate TrackerSparqlDataTablePrivate;
  191 typedef struct _TrackerSparqlVariableBindingListPrivate TrackerSparqlVariableBindingListPrivate;
  192 typedef struct _TrackerSparqlVariableBindingPrivate TrackerSparqlVariableBindingPrivate;
  193 #define _g_hash_table_unref0(var) ((var == NULL) ? NULL : (var = (g_hash_table_unref (var), NULL)))
  194 #define _vala_assert(expr, msg) if G_LIKELY (expr) ; else g_assertion_message_expr (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, msg);
  195 
  196 struct _TrackerSparqlPredicateVariable {
  197 	GObject parent_instance;
  198 	TrackerSparqlPredicateVariablePrivate * priv;
  199 	gchar* subject;
  200 	gchar* object;
  201 	gboolean return_graph;
  202 	TrackerClass* domain;
  203 };
  204 
  205 struct _TrackerSparqlPredicateVariableClass {
  206 	GObjectClass parent_class;
  207 };
  208 
  209 struct _TrackerSparqlDataBinding {
  210 	GObject parent_instance;
  211 	TrackerSparqlDataBindingPrivate * priv;
  212 	TrackerPropertyType data_type;
  213 	TrackerSparqlDataTable* table;
  214 	gchar* sql_db_column_name;
  215 };
  216 
  217 struct _TrackerSparqlDataBindingClass {
  218 	GObjectClass parent_class;
  219 };
  220 
  221 struct _TrackerSparqlLiteralBinding {
  222 	TrackerSparqlDataBinding parent_instance;
  223 	TrackerSparqlLiteralBindingPrivate * priv;
  224 	gboolean is_fts_match;
  225 	gchar* literal;
  226 };
  227 
  228 struct _TrackerSparqlLiteralBindingClass {
  229 	TrackerSparqlDataBindingClass parent_class;
  230 };
  231 
  232 struct _TrackerSparqlQuery {
  233 	GObject parent_instance;
  234 	TrackerSparqlQueryPrivate * priv;
  235 	TrackerSparqlExpression* expression;
  236 	TrackerSparqlPattern* pattern;
  237 	GList* bindings;
  238 	TrackerSparqlContext* context;
  239 	gint last_var_index;
  240 };
  241 
  242 struct _TrackerSparqlQueryClass {
  243 	GObjectClass parent_class;
  244 };
  245 
  246 struct _TrackerSparqlPattern {
  247 	GObject parent_instance;
  248 	TrackerSparqlPatternPrivate * priv;
  249 	gchar* current_graph;
  250 	TrackerSparqlVariable* fts_subject;
  251 	gchar** fts_variables;
  252 	gint fts_variables_length1;
  253 	gint _fts_variables_size_;
  254 	GString* match_str;
  255 	gboolean queries_fts_data;
  256 };
  257 
  258 struct _TrackerSparqlPatternClass {
  259 	GObjectClass parent_class;
  260 };
  261 
  262 struct _TrackerSparqlPatternPrivate {
  263 	TrackerSparqlQuery* query;
  264 	TrackerSparqlExpression* expression;
  265 	gint counter;
  266 	gint next_table_index;
  267 	gboolean current_graph_is_var;
  268 	gchar* current_subject;
  269 	gboolean current_subject_is_var;
  270 	gchar* current_predicate;
  271 	gboolean current_predicate_is_var;
  272 	TrackerSparqlPatternTripleContext* triple_context;
  273 };
  274 
  275 typedef enum  {
  276 	TRACKER_SPARQL_TOKEN_TYPE_NONE,
  277 	TRACKER_SPARQL_TOKEN_TYPE_A,
  278 	TRACKER_SPARQL_TOKEN_TYPE_AS,
  279 	TRACKER_SPARQL_TOKEN_TYPE_ASC,
  280 	TRACKER_SPARQL_TOKEN_TYPE_ASK,
  281 	TRACKER_SPARQL_TOKEN_TYPE_ATBASE,
  282 	TRACKER_SPARQL_TOKEN_TYPE_ATPREFIX,
  283 	TRACKER_SPARQL_TOKEN_TYPE_AVG,
  284 	TRACKER_SPARQL_TOKEN_TYPE_BASE,
  285 	TRACKER_SPARQL_TOKEN_TYPE_BLANK_NODE,
  286 	TRACKER_SPARQL_TOKEN_TYPE_BOUND,
  287 	TRACKER_SPARQL_TOKEN_TYPE_BY,
  288 	TRACKER_SPARQL_TOKEN_TYPE_CLOSE_BRACE,
  289 	TRACKER_SPARQL_TOKEN_TYPE_CLOSE_BRACKET,
  290 	TRACKER_SPARQL_TOKEN_TYPE_CLOSE_PARENS,
  291 	TRACKER_SPARQL_TOKEN_TYPE_COALESCE,
  292 	TRACKER_SPARQL_TOKEN_TYPE_COLON,
  293 	TRACKER_SPARQL_TOKEN_TYPE_COMMA,
  294 	TRACKER_SPARQL_TOKEN_TYPE_CONSTRUCT,
  295 	TRACKER_SPARQL_TOKEN_TYPE_COUNT,
  296 	TRACKER_SPARQL_TOKEN_TYPE_DATA,
  297 	TRACKER_SPARQL_TOKEN_TYPE_DATATYPE,
  298 	TRACKER_SPARQL_TOKEN_TYPE_DECIMAL,
  299 	TRACKER_SPARQL_TOKEN_TYPE_DELETE,
  300 	TRACKER_SPARQL_TOKEN_TYPE_DESC,
  301 	TRACKER_SPARQL_TOKEN_TYPE_DESCRIBE,
  302 	TRACKER_SPARQL_TOKEN_TYPE_DISTINCT,
  303 	TRACKER_SPARQL_TOKEN_TYPE_DIV,
  304 	TRACKER_SPARQL_TOKEN_TYPE_DOT,
  305 	TRACKER_SPARQL_TOKEN_TYPE_DOUBLE,
  306 	TRACKER_SPARQL_TOKEN_TYPE_DOUBLE_CIRCUMFLEX,
  307 	TRACKER_SPARQL_TOKEN_TYPE_DROP,
  308 	TRACKER_SPARQL_TOKEN_TYPE_EOF,
  309 	TRACKER_SPARQL_TOKEN_TYPE_EXISTS,
  310 	TRACKER_SPARQL_TOKEN_TYPE_FALSE,
  311 	TRACKER_SPARQL_TOKEN_TYPE_FILTER,
  312 	TRACKER_SPARQL_TOKEN_TYPE_FROM,
  313 	TRACKER_SPARQL_TOKEN_TYPE_GRAPH,
  314 	TRACKER_SPARQL_TOKEN_TYPE_GROUP,
  315 	TRACKER_SPARQL_TOKEN_TYPE_GROUP_CONCAT,
  316 	TRACKER_SPARQL_TOKEN_TYPE_HAVING,
  317 	TRACKER_SPARQL_TOKEN_TYPE_IF,
  318 	TRACKER_SPARQL_TOKEN_TYPE_INSERT,
  319 	TRACKER_SPARQL_TOKEN_TYPE_INTEGER,
  320 	TRACKER_SPARQL_TOKEN_TYPE_INTO,
  321 	TRACKER_SPARQL_TOKEN_TYPE_IRI_REF,
  322 	TRACKER_SPARQL_TOKEN_TYPE_ISBLANK,
  323 	TRACKER_SPARQL_TOKEN_TYPE_ISIRI,
  324 	TRACKER_SPARQL_TOKEN_TYPE_ISLITERAL,
  325 	TRACKER_SPARQL_TOKEN_TYPE_ISURI,
  326 	TRACKER_SPARQL_TOKEN_TYPE_LANG,
  327 	TRACKER_SPARQL_TOKEN_TYPE_LANGMATCHES,
  328 	TRACKER_SPARQL_TOKEN_TYPE_LIMIT,
  329 	TRACKER_SPARQL_TOKEN_TYPE_MAX,
  330 	TRACKER_SPARQL_TOKEN_TYPE_MIN,
  331 	TRACKER_SPARQL_TOKEN_TYPE_MINUS,
  332 	TRACKER_SPARQL_TOKEN_TYPE_NAMED,
  333 	TRACKER_SPARQL_TOKEN_TYPE_NOT,
  334 	TRACKER_SPARQL_TOKEN_TYPE_NULL,
  335 	TRACKER_SPARQL_TOKEN_TYPE_OFFSET,
  336 	TRACKER_SPARQL_TOKEN_TYPE_OP_AND,
  337 	TRACKER_SPARQL_TOKEN_TYPE_OP_EQ,
  338 	TRACKER_SPARQL_TOKEN_TYPE_OP_GE,
  339 	TRACKER_SPARQL_TOKEN_TYPE_OP_GT,
  340 	TRACKER_SPARQL_TOKEN_TYPE_OP_LE,
  341 	TRACKER_SPARQL_TOKEN_TYPE_OP_LT,
  342 	TRACKER_SPARQL_TOKEN_TYPE_OP_NE,
  343 	TRACKER_SPARQL_TOKEN_TYPE_OP_NEG,
  344 	TRACKER_SPARQL_TOKEN_TYPE_OP_OR,
  345 	TRACKER_SPARQL_TOKEN_TYPE_OP_IN,
  346 	TRACKER_SPARQL_TOKEN_TYPE_OPEN_BRACE,
  347 	TRACKER_SPARQL_TOKEN_TYPE_OPEN_BRACKET,
  348 	TRACKER_SPARQL_TOKEN_TYPE_OPEN_PARENS,
  349 	TRACKER_SPARQL_TOKEN_TYPE_OPTIONAL,
  350 	TRACKER_SPARQL_TOKEN_TYPE_OR,
  351 	TRACKER_SPARQL_TOKEN_TYPE_ORDER,
  352 	TRACKER_SPARQL_TOKEN_TYPE_PLUS,
  353 	TRACKER_SPARQL_TOKEN_TYPE_PN_PREFIX,
  354 	TRACKER_SPARQL_TOKEN_TYPE_PREFIX,
  355 	TRACKER_SPARQL_TOKEN_TYPE_REDUCED,
  356 	TRACKER_SPARQL_TOKEN_TYPE_REGEX,
  357 	TRACKER_SPARQL_TOKEN_TYPE_REPLACE,
  358 	TRACKER_SPARQL_TOKEN_TYPE_SAMETERM,
  359 	TRACKER_SPARQL_TOKEN_TYPE_SELECT,
  360 	TRACKER_SPARQL_TOKEN_TYPE_SEMICOLON,
  361 	TRACKER_SPARQL_TOKEN_TYPE_SILENT,
  362 	TRACKER_SPARQL_TOKEN_TYPE_STAR,
  363 	TRACKER_SPARQL_TOKEN_TYPE_STR,
  364 	TRACKER_SPARQL_TOKEN_TYPE_STRING_LITERAL1,
  365 	TRACKER_SPARQL_TOKEN_TYPE_STRING_LITERAL2,
  366 	TRACKER_SPARQL_TOKEN_TYPE_STRING_LITERAL_LONG1,
  367 	TRACKER_SPARQL_TOKEN_TYPE_STRING_LITERAL_LONG2,
  368 	TRACKER_SPARQL_TOKEN_TYPE_SUM,
  369 	TRACKER_SPARQL_TOKEN_TYPE_TRUE,
  370 	TRACKER_SPARQL_TOKEN_TYPE_UNION,
  371 	TRACKER_SPARQL_TOKEN_TYPE_VAR,
  372 	TRACKER_SPARQL_TOKEN_TYPE_WHERE,
  373 	TRACKER_SPARQL_TOKEN_TYPE_WITH
  374 } TrackerSparqlTokenType;
  375 
  376 struct _TrackerSourceLocation {
  377 	gchar* pos;
  378 	gint line;
  379 	gint column;
  380 };
  381 
  382 struct _TrackerSparqlContext {
  383 	GTypeInstance parent_instance;
  384 	volatile int ref_count;
  385 	TrackerSparqlContextPrivate * priv;
  386 	TrackerSparqlQuery* query;
  387 	TrackerSparqlContext* parent_context;
  388 	GHashTable* var_set;
  389 	GHashTable* var_map;
  390 	GHashTable* select_var_set;
  391 	GHashTable* predicate_variable_map;
  392 	gboolean scalar_subquery;
  393 };
  394 
  395 struct _TrackerSparqlContextClass {
  396 	GTypeClass parent_class;
  397 	void (*finalize) (TrackerSparqlContext *self);
  398 };
  399 
  400 typedef enum  {
  401 	TRACKER_SPARQL_VARIABLE_STATE_NONE,
  402 	TRACKER_SPARQL_VARIABLE_STATE_BOUND,
  403 	TRACKER_SPARQL_VARIABLE_STATE_OPTIONAL
  404 } TrackerSparqlVariableState;
  405 
  406 struct _TrackerSparqlVariable {
  407 	GObject parent_instance;
  408 	TrackerSparqlVariablePrivate * priv;
  409 	TrackerSparqlVariableBinding* binding;
  410 };
  411 
  412 struct _TrackerSparqlVariableClass {
  413 	GObjectClass parent_class;
  414 };
  415 
  416 struct _TrackerSparqlSelectContext {
  417 	TrackerSparqlContext parent_instance;
  418 	TrackerSparqlSelectContextPrivate * priv;
  419 	TrackerPropertyType type;
  420 	TrackerPropertyType* types;
  421 	gint types_length1;
  422 	gint _types_size_;
  423 	gchar** variable_names;
  424 	gint variable_names_length1;
  425 	gint _variable_names_size_;
  426 };
  427 
  428 struct _TrackerSparqlSelectContextClass {
  429 	TrackerSparqlContextClass parent_class;
  430 };
  431 
  432 struct _TrackerSparqlPatternTripleContext {
  433 	TrackerSparqlContext parent_instance;
  434 	TrackerSparqlPatternTripleContextPrivate * priv;
  435 	GList* tables;
  436 	GHashTable* table_map;
  437 	GList* bindings;
  438 	GList* variables;
  439 	GHashTable* var_bindings;
  440 };
  441 
  442 struct _TrackerSparqlPatternTripleContextClass {
  443 	TrackerSparqlContextClass parent_class;
  444 };
  445 
  446 struct _TrackerSparqlDataTable {
  447 	GObject parent_instance;
  448 	TrackerSparqlDataTablePrivate * priv;
  449 	gchar* sql_db_tablename;
  450 	gchar* sql_query_tablename;
  451 	TrackerSparqlPredicateVariable* predicate_variable;
  452 };
  453 
  454 struct _TrackerSparqlDataTableClass {
  455 	GObjectClass parent_class;
  456 };
  457 
  458 struct _TrackerSparqlVariableBindingList {
  459 	GObject parent_instance;
  460 	TrackerSparqlVariableBindingListPrivate * priv;
  461 	GList* list;
  462 };
  463 
  464 struct _TrackerSparqlVariableBindingListClass {
  465 	GObjectClass parent_class;
  466 };
  467 
  468 struct _TrackerSparqlVariableBinding {
  469 	TrackerSparqlDataBinding parent_instance;
  470 	TrackerSparqlVariableBindingPrivate * priv;
  471 	TrackerSparqlVariable* variable;
  472 	gboolean maybe_null;
  473 	gboolean in_simple_optional;
  474 	TrackerClass* type;
  475 };
  476 
  477 struct _TrackerSparqlVariableBindingClass {
  478 	TrackerSparqlDataBindingClass parent_class;
  479 };
  480 
  481 
  482 static gpointer tracker_sparql_predicate_variable_parent_class = NULL;
  483 static gpointer tracker_sparql_pattern_parent_class = NULL;
  484 static gpointer tracker_sparql_pattern_triple_context_parent_class = NULL;
  485 
  486 GType tracker_sparql_predicate_variable_get_type (void) G_GNUC_CONST;
  487 enum  {
  488 	TRACKER_SPARQL_PREDICATE_VARIABLE_DUMMY_PROPERTY
  489 };
  490 GType tracker_sparql_query_get_type (void) G_GNUC_CONST;
  491 gchar* tracker_sparql_predicate_variable_get_sql_query (TrackerSparqlPredicateVariable* self, TrackerSparqlQuery* query, GError** error);
  492 void tracker_sparql_expression_append_expression_as_string (GString* sql, const gchar* expression, TrackerPropertyType type);
  493 TrackerSparqlLiteralBinding* tracker_sparql_literal_binding_new (void);
  494 TrackerSparqlLiteralBinding* tracker_sparql_literal_binding_construct (GType object_type);
  495 GType tracker_sparql_data_binding_get_type (void) G_GNUC_CONST;
  496 GType tracker_sparql_literal_binding_get_type (void) G_GNUC_CONST;
  497 GType tracker_sparql_data_table_get_type (void) G_GNUC_CONST;
  498 GType tracker_sparql_expression_get_type (void) G_GNUC_CONST;
  499 GType tracker_sparql_pattern_get_type (void) G_GNUC_CONST;
  500 gpointer tracker_sparql_context_ref (gpointer instance);
  501 void tracker_sparql_context_unref (gpointer instance);
  502 GParamSpec* tracker_sparql_param_spec_context (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
  503 void tracker_sparql_value_set_context (GValue* value, gpointer v_object);
  504 void tracker_sparql_value_take_context (GValue* value, gpointer v_object);
  505 gpointer tracker_sparql_value_get_context (const GValue* value);
  506 GType tracker_sparql_context_get_type (void) G_GNUC_CONST;
  507 GError* tracker_sparql_query_get_internal_error (TrackerSparqlQuery* self, const gchar* msg);
  508 TrackerSparqlPredicateVariable* tracker_sparql_predicate_variable_new (void);
  509 TrackerSparqlPredicateVariable* tracker_sparql_predicate_variable_construct (GType object_type);
  510 static void tracker_sparql_predicate_variable_finalize (GObject* obj);
  511 GType tracker_sparql_variable_get_type (void) G_GNUC_CONST;
  512 static GType tracker_sparql_pattern_triple_context_get_type (void) G_GNUC_CONST G_GNUC_UNUSED;
  513 #define TRACKER_SPARQL_PATTERN_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TRACKER_SPARQL_TYPE_PATTERN, TrackerSparqlPatternPrivate))
  514 enum  {
  515 	TRACKER_SPARQL_PATTERN_DUMMY_PROPERTY
  516 };
  517 TrackerSparqlPattern* tracker_sparql_pattern_new (TrackerSparqlQuery* query);
  518 TrackerSparqlPattern* tracker_sparql_pattern_construct (GType object_type, TrackerSparqlQuery* query);
  519 static inline gboolean tracker_sparql_pattern_next (TrackerSparqlPattern* self, GError** error);
  520 gboolean tracker_sparql_query_next (TrackerSparqlQuery* self, GError** error);
  521 GType tracker_sparql_token_type_get_type (void) G_GNUC_CONST;
  522 static inline TrackerSparqlTokenType tracker_sparql_pattern_current (TrackerSparqlPattern* self);
  523 TrackerSparqlTokenType tracker_sparql_query_current (TrackerSparqlQuery* self);
  524 static inline gboolean tracker_sparql_pattern_accept (TrackerSparqlPattern* self, TrackerSparqlTokenType type, GError** error);
  525 gboolean tracker_sparql_query_accept (TrackerSparqlQuery* self, TrackerSparqlTokenType type, GError** error);
  526 static GError* tracker_sparql_pattern_get_error (TrackerSparqlPattern* self, const gchar* msg);
  527 GError* tracker_sparql_query_get_error (TrackerSparqlQuery* self, const gchar* msg);
  528 static gboolean tracker_sparql_pattern_expect (TrackerSparqlPattern* self, TrackerSparqlTokenType type, GError** error);
  529 gboolean tracker_sparql_query_expect (TrackerSparqlQuery* self, TrackerSparqlTokenType type, GError** error);
  530 GType tracker_source_location_get_type (void) G_GNUC_CONST;
  531 TrackerSourceLocation* tracker_source_location_dup (const TrackerSourceLocation* self);
  532 void tracker_source_location_free (TrackerSourceLocation* self);
  533 static void tracker_sparql_pattern_get_location (TrackerSparqlPattern* self, TrackerSourceLocation* result);
  534 void tracker_sparql_query_get_location (TrackerSparqlQuery* self, TrackerSourceLocation* result);
  535 static void tracker_sparql_pattern_set_location (TrackerSparqlPattern* self, TrackerSourceLocation* location);
  536 void tracker_sparql_query_set_location (TrackerSparqlQuery* self, TrackerSourceLocation* location);
  537 static gchar* tracker_sparql_pattern_get_last_string (TrackerSparqlPattern* self, gint strip);
  538 gchar* tracker_sparql_query_get_last_string (TrackerSparqlQuery* self, gint strip);
  539 GType tracker_sparql_select_context_get_type (void) G_GNUC_CONST;
  540 TrackerSparqlSelectContext* tracker_sparql_pattern_translate_select (TrackerSparqlPattern* self, GString* sql, gboolean subquery, gboolean scalar_subquery, GError** error);
  541 static TrackerSparqlContext* tracker_sparql_pattern_get_context (TrackerSparqlPattern* self);
  542 TrackerSparqlSelectContext* tracker_sparql_select_context_new_subquery (TrackerSparqlQuery* query, TrackerSparqlContext* parent_context);
  543 TrackerSparqlSelectContext* tracker_sparql_select_context_construct_subquery (GType object_type, TrackerSparqlQuery* query, TrackerSparqlContext* parent_context);
  544 TrackerSparqlSelectContext* tracker_sparql_select_context_new (TrackerSparqlQuery* query, TrackerSparqlContext* parent_context);
  545 TrackerSparqlSelectContext* tracker_sparql_select_context_construct (GType object_type, TrackerSparqlQuery* query, TrackerSparqlContext* parent_context);
  546 static void tracker_sparql_pattern_set_context (TrackerSparqlPattern* self, TrackerSparqlContext* value);
  547 static void _g_object_unref0_ (gpointer var);
  548 static void _g_list_free__g_object_unref0_ (GList* self);
  549 void tracker_sparql_expression_skip_select_variables (TrackerSparqlExpression* self, GError** error);
  550 TrackerSparqlContext* tracker_sparql_pattern_translate_group_graph_pattern (TrackerSparqlPattern* self, GString* sql, GError** error);
  551 GType tracker_sparql_variable_state_get_type (void) G_GNUC_CONST;
  552 GType tracker_sparql_variable_binding_get_type (void) G_GNUC_CONST;
  553 const gchar* tracker_sparql_variable_get_name (TrackerSparqlVariable* self);
  554 const gchar* tracker_sparql_variable_get_sql_expression (TrackerSparqlVariable* self);
  555 static void _vala_array_add5 (TrackerPropertyType** array, int* length, int* size, TrackerPropertyType value);
  556 static void _vala_array_add6 (gchar*** array, int* length, int* size, gchar* value);
  557 TrackerPropertyType tracker_sparql_expression_translate_select_expression (TrackerSparqlExpression* self, GString* sql, gboolean subquery, gint variable_index, GError** error);
  558 static void _vala_array_add7 (TrackerPropertyType** array, int* length, int* size, TrackerPropertyType value);
  559 TrackerPropertyType tracker_sparql_expression_translate_expression (TrackerSparqlExpression* self, GString* sql, GError** error);
  560 TrackerPropertyType tracker_sparql_expression_translate_constraint (TrackerSparqlExpression* self, GString* sql, GError** error);
  561 void tracker_sparql_expression_translate_order_condition (TrackerSparqlExpression* self, GString* sql, GError** error);
  562 void tracker_sparql_pattern_translate_exists (TrackerSparqlPattern* self, GString* sql, GError** error);
  563 gchar* tracker_sparql_pattern_parse_var_or_term (TrackerSparqlPattern* self, GString* sql, gboolean* is_var, GError** error);
  564 gchar* tracker_sparql_query_resolve_prefixed_name (TrackerSparqlQuery* self, const gchar* prefix, const gchar* local_name, GError** error);
  565 gchar* tracker_sparql_query_generate_bnodeid (TrackerSparqlQuery* self, const gchar* user_bnodeid);
  566 gchar* tracker_sparql_expression_parse_string_literal (TrackerSparqlExpression* self, TrackerPropertyType* type, GError** error);
  567 static void tracker_sparql_pattern_parse_property_list_not_empty (TrackerSparqlPattern* self, GString* sql, gboolean in_simple_optional, GError** error);
  568 static void tracker_sparql_pattern_parse_object_list (TrackerSparqlPattern* self, GString* sql, gboolean in_simple_optional, GError** error);
  569 static void tracker_sparql_pattern_parse_object (TrackerSparqlPattern* self, GString* sql, gboolean in_simple_optional, GError** error);
  570 static void tracker_sparql_pattern_translate_filter (TrackerSparqlPattern* self, GString* sql, GError** error);
  571 static void tracker_sparql_pattern_skip_filter (TrackerSparqlPattern* self, GError** error);
  572 static void tracker_sparql_pattern_start_triples_block (TrackerSparqlPattern* self, GString* sql, GError** error);
  573 static TrackerSparqlPatternTripleContext* tracker_sparql_pattern_triple_context_new (TrackerSparqlQuery* query, TrackerSparqlContext* parent_context);
  574 static TrackerSparqlPatternTripleContext* tracker_sparql_pattern_triple_context_construct (GType object_type, TrackerSparqlQuery* query, TrackerSparqlContext* parent_context);
  575 static void tracker_sparql_pattern_end_triples_block (TrackerSparqlPattern* self, GString* sql, gboolean* first_where, gboolean in_group_graph_pattern, GError** error);
  576 GType tracker_sparql_variable_binding_list_get_type (void) G_GNUC_CONST;
  577 const gchar* tracker_sparql_data_binding_get_sql_expression (TrackerSparqlDataBinding* self);
  578 static void tracker_sparql_pattern_parse_triples (TrackerSparqlPattern* self, GString* sql, glong group_graph_pattern_start, gboolean* in_triples_block, gboolean* first_where, gboolean* in_group_graph_pattern, gboolean found_simple_optional, GError** error);
  579 static gboolean tracker_sparql_pattern_is_subclass (TrackerSparqlPattern* self, TrackerClass* class1, TrackerClass* class2);
  580 static gboolean tracker_sparql_pattern_is_simple_optional (TrackerSparqlPattern* self);
  581 TrackerSparqlVariable* tracker_sparql_context_get_variable (TrackerSparqlContext* self, const gchar* name);
  582 guint tracker_sparql_variable_hash (TrackerSparqlVariable* variable);
  583 static guint _tracker_sparql_variable_hash_ghash_func (gconstpointer key);
  584 gboolean tracker_sparql_variable_equal (TrackerSparqlVariable* a, TrackerSparqlVariable* b);
  585 static gboolean _tracker_sparql_variable_equal_gequal_func (gconstpointer a, gconstpointer b);
  586 TrackerSparqlContext* tracker_sparql_context_new (TrackerSparqlQuery* query, TrackerSparqlContext* parent_context);
  587 TrackerSparqlContext* tracker_sparql_context_construct (GType object_type, TrackerSparqlQuery* query, TrackerSparqlContext* parent_context);
  588 gchar* tracker_sparql_variable_get_extra_sql_expression (TrackerSparqlVariable* self, const gchar* suffix);
  589 static void tracker_sparql_pattern_translate_group_or_union_graph_pattern (TrackerSparqlPattern* self, GString* sql, GError** error);
  590 static void _vala_array_add8 (TrackerSourceLocation** array, int* length, int* size, const TrackerSourceLocation* value);
  591 static void _vala_array_add9 (glong** array, int* length, int* size, glong value);
  592 static void _vala_array_add10 (TrackerSparqlContext*** array, int* length, int* size, TrackerSparqlContext* value);
  593 static void _vala_array_add11 (TrackerSparqlVariable*** array, int* length, int* size, TrackerSparqlVariable* value);
  594 static TrackerSparqlVariableBindingList* tracker_sparql_pattern_get_variable_binding_list (TrackerSparqlPattern* self, TrackerSparqlVariable* variable);
  595 TrackerSparqlVariableBinding* tracker_sparql_variable_binding_new (void);
  596 TrackerSparqlVariableBinding* tracker_sparql_variable_binding_construct (GType object_type);
  597 void tracker_sparql_data_binding_set_sql_expression (TrackerSparqlDataBinding* self, const gchar* value);
  598 TrackerSparqlVariableBindingList* tracker_sparql_variable_binding_list_new (void);
  599 TrackerSparqlVariableBindingList* tracker_sparql_variable_binding_list_construct (GType object_type);
  600 void tracker_sparql_pattern_add_variable_binding (TrackerSparqlPattern* self, GString* sql, TrackerSparqlVariableBinding* binding, TrackerSparqlVariableState variable_state);
  601 gchar* tracker_sparql_data_binding_get_extra_sql_expression (TrackerSparqlDataBinding* self, const gchar* suffix);
  602 static TrackerSparqlDataTable* tracker_sparql_pattern_get_table (TrackerSparqlPattern* self, const gchar* subject, const gchar* db_table, gboolean share_table, gboolean* newtable);
  603 TrackerSparqlDataTable* tracker_sparql_data_table_new (void);
  604 TrackerSparqlDataTable* tracker_sparql_data_table_construct (GType object_type);
  605 enum  {
  606 	TRACKER_SPARQL_PATTERN_TRIPLE_CONTEXT_DUMMY_PROPERTY
  607 };
  608 static void tracker_sparql_pattern_triple_context_finalize (TrackerSparqlContext* obj);
  609 static void tracker_sparql_pattern_finalize (GObject* obj);
  610 static void _vala_tracker_sparql_pattern_get_property (GObject * object, guint property_id, GValue * value, GParamSpec * pspec);
  611 static void _vala_tracker_sparql_pattern_set_property (GObject * object, guint property_id, const GValue * value, GParamSpec * pspec);
  612 static void _vala_array_destroy (gpointer array, gint array_length, GDestroyNotify destroy_func);
  613 static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify destroy_func);
  614 static gint _vala_array_length (gpointer array);
  615 
  616 
  617 static gpointer _g_object_ref0 (gpointer self) {
  618 #line 39 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  619 	return self ? g_object_ref (self) : NULL;
  620 #line 621 "tracker-sparql-pattern.c"
  621 }
  622 
  623 
  624 gchar* tracker_sparql_predicate_variable_get_sql_query (TrackerSparqlPredicateVariable* self, TrackerSparqlQuery* query, GError** error) {
  625 	gchar* result = NULL;
  626 	GError * _inner_error_ = NULL;
  627 #line 29 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  628 	g_return_val_if_fail (self != NULL, NULL);
  629 #line 29 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  630 	g_return_val_if_fail (query != NULL, NULL);
  631 #line 632 "tracker-sparql-pattern.c"
  632 	{
  633 		GString* _tmp0_;
  634 		GString* sql;
  635 		const gchar* _tmp1_;
  636 		GString* _tmp153_;
  637 		const gchar* _tmp154_;
  638 		gchar* _tmp155_;
  639 #line 31 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  640 		_tmp0_ = g_string_new ("");
  641 #line 31 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  642 		sql = _tmp0_;
  643 #line 33 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  644 		_tmp1_ = self->subject;
  645 #line 33 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  646 		if (_tmp1_ != NULL) {
  647 #line 648 "tracker-sparql-pattern.c"
  648 			const gchar* _tmp2_;
  649 			gint _tmp3_ = 0;
  650 			gint subject_id;
  651 			TrackerDBCursor* cursor;
  652 			gint _tmp4_;
  653 			gboolean first;
  654 			TrackerDBCursor* _tmp14_;
  655 			gboolean _tmp63_;
  656 #line 35 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  657 			_tmp2_ = self->subject;
  658 #line 35 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  659 			_tmp3_ = tracker_data_query_resource_id (_tmp2_);
  660 #line 35 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  661 			subject_id = _tmp3_;
  662 #line 37 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  663 			cursor = NULL;
  664 #line 38 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  665 			_tmp4_ = subject_id;
  666 #line 38 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  667 			if (_tmp4_ > 0) {
  668 #line 669 "tracker-sparql-pattern.c"
  669 				TrackerDBInterface* _tmp5_ = NULL;
  670 				TrackerDBInterface* _tmp6_;
  671 				TrackerDBInterface* iface;
  672 				TrackerDBInterface* _tmp7_;
  673 				TrackerDBStatement* _tmp8_ = NULL;
  674 				TrackerDBStatement* stmt;
  675 				TrackerDBStatement* _tmp9_;
  676 				gint _tmp10_;
  677 				TrackerDBStatement* _tmp11_;
  678 				TrackerDBCursor* _tmp12_ = NULL;
  679 				TrackerDBCursor* _tmp13_;
  680 #line 39 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  681 				_tmp5_ = tracker_db_manager_get_db_interface ();
  682 #line 39 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  683 				_tmp6_ = _g_object_ref0 (_tmp5_);
  684 #line 39 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  685 				iface = _tmp6_;
  686 #line 40 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  687 				_tmp7_ = iface;
  688 #line 40 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  689 				_tmp8_ = tracker_db_interface_create_statement (_tmp7_, TRACKER_DB_STATEMENT_CACHE_TYPE_SELECT, &_inner_error_, "SELECT (SELECT Uri FROM Resource WHERE ID = \"rdf:type\") " "FROM \"rdfs:Resource_rdf:type\" WHERE ID = ?");
  690 #line 40 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  691 				stmt = _tmp8_;
  692 #line 40 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  693 				if (_inner_error_ != NULL) {
  694 #line 40 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  695 					_g_object_unref0 (iface);
  696 #line 40 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  697 					_g_object_unref0 (cursor);
  698 #line 40 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  699 					_g_string_free0 (sql);
  700 #line 701 "tracker-sparql-pattern.c"
  701 					goto __catch0_g_error;
  702 				}
  703 #line 43 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  704 				_tmp9_ = stmt;
  705 #line 43 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  706 				_tmp10_ = subject_id;
  707 #line 43 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  708 				tracker_db_statement_bind_int (_tmp9_, 0, _tmp10_);
  709 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  710 				_tmp11_ = stmt;
  711 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  712 				_tmp12_ = tracker_db_statement_start_cursor (_tmp11_, &_inner_error_);
  713 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  714 				_tmp13_ = _tmp12_;
  715 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  716 				if (_inner_error_ != NULL) {
  717 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  718 					_g_object_unref0 (stmt);
  719 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  720 					_g_object_unref0 (iface);
  721 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  722 					_g_object_unref0 (cursor);
  723 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  724 					_g_string_free0 (sql);
  725 #line 726 "tracker-sparql-pattern.c"
  726 					goto __catch0_g_error;
  727 				}
  728 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  729 				_g_object_unref0 (cursor);
  730 #line 44 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  731 				cursor = _tmp13_;
  732 #line 38 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  733 				_g_object_unref0 (stmt);
  734 #line 38 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  735 				_g_object_unref0 (iface);
  736 #line 737 "tracker-sparql-pattern.c"
  737 			}
  738 #line 47 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  739 			first = TRUE;
  740 #line 48 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  741 			_tmp14_ = cursor;
  742 #line 48 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  743 			if (_tmp14_ != NULL) {
  744 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  745 				while (TRUE) {
  746 #line 747 "tracker-sparql-pattern.c"
  747 					TrackerDBCursor* _tmp15_;
  748 					gboolean _tmp16_ = FALSE;
  749 					gboolean _tmp17_;
  750 					TrackerDBCursor* _tmp18_;
  751 					const gchar* _tmp19_ = NULL;
  752 					TrackerClass* _tmp20_ = NULL;
  753 					TrackerClass* _tmp21_;
  754 					TrackerClass* domain;
  755 					gint _tmp22_ = 0;
  756 					TrackerProperty** _tmp23_ = NULL;
  757 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  758 					_tmp15_ = cursor;
  759 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  760 					_tmp16_ = tracker_sparql_cursor_next ((TrackerSparqlCursor*) _tmp15_, NULL, &_inner_error_);
  761 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  762 					_tmp17_ = _tmp16_;
  763 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  764 					if (_inner_error_ != NULL) {
  765 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  766 						_g_object_unref0 (cursor);
  767 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  768 						_g_string_free0 (sql);
  769 #line 770 "tracker-sparql-pattern.c"
  770 						goto __catch0_g_error;
  771 					}
  772 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  773 					if (!_tmp17_) {
  774 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  775 						break;
  776 #line 777 "tracker-sparql-pattern.c"
  777 					}
  778 #line 50 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  779 					_tmp18_ = cursor;
  780 #line 50 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  781 					_tmp19_ = tracker_sparql_cursor_get_string ((TrackerSparqlCursor*) _tmp18_, 0, NULL);
  782 #line 50 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  783 					_tmp20_ = tracker_ontologies_get_class_by_uri (_tmp19_);
  784 #line 50 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  785 					_tmp21_ = _g_object_ref0 (_tmp20_);
  786 #line 50 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  787 					domain = _tmp21_;
  788 #line 52 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  789 					_tmp23_ = tracker_ontologies_get_properties (&_tmp22_);
  790 #line 791 "tracker-sparql-pattern.c"
  791 					{
  792 						TrackerProperty** prop_collection = NULL;
  793 						gint prop_collection_length1 = 0;
  794 						gint _prop_collection_size_ = 0;
  795 						gint prop_it = 0;
  796 #line 52 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  797 						prop_collection = _tmp23_;
  798 #line 52 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
  799 						prop_collection_length1 = _tmp22_;
Value stored to 'prop_collection_length1' is never read
(emitted by clang-analyzer)

TODO: a detailed trace is available in the data model (not yet rendered in this report)

800 #line 52 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 801 for (prop_it = 0; prop_it < _tmp22_; prop_it = prop_it + 1) { 802 #line 803 "tracker-sparql-pattern.c" 803 TrackerProperty* _tmp24_; 804 TrackerProperty* prop = NULL; 805 #line 52 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 806 _tmp24_ = _g_object_ref0 (prop_collection[prop_it]); 807 #line 52 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 808 prop = _tmp24_; 809 #line 810 "tracker-sparql-pattern.c" 810 { 811 TrackerProperty* _tmp25_; 812 TrackerClass* _tmp26_; 813 TrackerClass* _tmp27_; 814 TrackerClass* _tmp28_; 815 #line 53 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 816 _tmp25_ = prop; 817 #line 53 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 818 _tmp26_ = tracker_property_get_domain (_tmp25_); 819 #line 53 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 820 _tmp27_ = _tmp26_; 821 #line 53 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 822 _tmp28_ = domain; 823 #line 53 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 824 if (_tmp27_ == _tmp28_) { 825 #line 826 "tracker-sparql-pattern.c" 826 gboolean _tmp29_; 827 GString* _tmp31_; 828 TrackerProperty* _tmp32_; 829 const gchar* _tmp33_; 830 const gchar* _tmp34_; 831 GString* _tmp35_; 832 TrackerProperty* _tmp36_; 833 const gchar* _tmp37_; 834 const gchar* _tmp38_; 835 gchar* _tmp39_ = NULL; 836 gchar* _tmp40_; 837 TrackerProperty* _tmp41_; 838 TrackerPropertyType _tmp42_; 839 TrackerPropertyType _tmp43_; 840 GString* _tmp44_; 841 gboolean _tmp45_; 842 GString* _tmp50_; 843 TrackerProperty* _tmp51_; 844 const gchar* _tmp52_; 845 const gchar* _tmp53_; 846 GString* _tmp54_; 847 TrackerSparqlLiteralBinding* _tmp55_; 848 TrackerSparqlLiteralBinding* binding; 849 TrackerSparqlLiteralBinding* _tmp56_; 850 gint _tmp57_; 851 gchar* _tmp58_ = NULL; 852 TrackerSparqlLiteralBinding* _tmp59_; 853 TrackerSparqlQuery* _tmp60_; 854 TrackerSparqlLiteralBinding* _tmp61_; 855 TrackerSparqlLiteralBinding* _tmp62_; 856 #line 54 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 857 _tmp29_ = first; 858 #line 54 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 859 if (_tmp29_) { 860 #line 55 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 861 first = FALSE; 862 #line 863 "tracker-sparql-pattern.c" 863 } else { 864 GString* _tmp30_; 865 #line 57 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 866 _tmp30_ = sql; 867 #line 57 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 868 g_string_append (_tmp30_, " UNION ALL "); 869 #line 870 "tracker-sparql-pattern.c" 870 } 871 #line 59 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 872 _tmp31_ = sql; 873 #line 59 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 874 _tmp32_ = prop; 875 #line 59 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 876 _tmp33_ = tracker_property_get_uri (_tmp32_); 877 #line 59 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 878 _tmp34_ = _tmp33_; 879 #line 59 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 880 g_string_append_printf (_tmp31_, "SELECT ID, (SELECT ID FROM Resource WHERE Uri = '%s') AS \"predicate\"" \ 881 ", ", _tmp34_); 882 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 883 _tmp35_ = sql; 884 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 885 _tmp36_ = prop; 886 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 887 _tmp37_ = tracker_property_get_name (_tmp36_); 888 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 889 _tmp38_ = _tmp37_; 890 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 891 _tmp39_ = g_strdup_printf ("\"%s\"", _tmp38_); 892 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 893 _tmp40_ = _tmp39_; 894 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 895 _tmp41_ = prop; 896 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 897 _tmp42_ = tracker_property_get_data_type (_tmp41_); 898 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 899 _tmp43_ = _tmp42_; 900 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 901 tracker_sparql_expression_append_expression_as_string (_tmp35_, _tmp40_, _tmp43_); 902 #line 61 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 903 _g_free0 (_tmp40_); 904 #line 63 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 905 _tmp44_ = sql; 906 #line 63 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 907 g_string_append (_tmp44_, " AS \"object\""); 908 #line 64 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 909 _tmp45_ = self->return_graph; 910 #line 64 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 911 if (_tmp45_) { 912 #line 912 "tracker-sparql-pattern.c" 913 GString* _tmp46_; 914 TrackerProperty* _tmp47_; 915 const gchar* _tmp48_; 916 const gchar* _tmp49_; 917 #line 65 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 918 _tmp46_ = sql; 919 #line 65 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 920 _tmp47_ = prop; 921 #line 65 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 922 _tmp48_ = tracker_property_get_name (_tmp47_); 923 #line 65 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 924 _tmp49_ = _tmp48_; 925 #line 65 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 926 g_string_append_printf (_tmp46_, ", \"%s:graph\" AS \"graph\"", _tmp49_); 927 #line 927 "tracker-sparql-pattern.c" 928 } 929 #line 67 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 930 _tmp50_ = sql; 931 #line 67 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 932 _tmp51_ = prop; 933 #line 67 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 934 _tmp52_ = tracker_property_get_table_name (_tmp51_); 935 #line 67 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 936 _tmp53_ = _tmp52_; 937 #line 67 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 938 g_string_append_printf (_tmp50_, " FROM \"%s\"", _tmp53_); 939 #line 69 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 940 _tmp54_ = sql; 941 #line 69 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 942 g_string_append (_tmp54_, " WHERE ID = ?"); 943 #line 71 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 944 _tmp55_ = tracker_sparql_literal_binding_new (); 945 #line 71 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 946 binding = _tmp55_; 947 #line 72 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 948 _tmp56_ = binding; 949 #line 72 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 950 _tmp57_ = subject_id; 951 #line 72 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 952 _tmp58_ = g_strdup_printf ("%i", _tmp57_); 953 #line 72 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 954 _g_free0 (_tmp56_->literal); 955 #line 72 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 956 _tmp56_->literal = _tmp58_; 957 #line 73 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 958 _tmp59_ = binding; 959 #line 73 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 960 ((TrackerSparqlDataBinding*) _tmp59_)->data_type = TRACKER_PROPERTY_TYPE_INTEGER; 961 #line 74 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 962 _tmp60_ = query; 963 #line 74 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 964 _tmp61_ = binding; 965 #line 74 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 966 _tmp62_ = _g_object_ref0 (_tmp61_); 967 #line 74 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 968 _tmp60_->bindings = g_list_append (_tmp60_->bindings, _tmp62_); 969 #line 53 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 970 _g_object_unref0 (binding); 971 #line 971 "tracker-sparql-pattern.c" 972 } 973 #line 52 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 974 _g_object_unref0 (prop); 975 #line 975 "tracker-sparql-pattern.c" 976 } 977 } 978 } 979 #line 49 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 980 _g_object_unref0 (domain); 981 #line 981 "tracker-sparql-pattern.c" 982 } 983 } 984 #line 80 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 985 _tmp63_ = first; 986 #line 80 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 987 if (_tmp63_) { 988 #line 988 "tracker-sparql-pattern.c" 989 GString* _tmp64_; 990 #line 82 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 991 _tmp64_ = sql; 992 #line 82 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 993 g_string_append (_tmp64_, "SELECT NULL AS ID, NULL AS \"predicate\", NULL AS \"object\", NULL AS " \ 994 "\"graph\""); 995 #line 994 "tracker-sparql-pattern.c" 996 } 997 #line 33 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 998 _g_object_unref0 (cursor); 999 #line 998 "tracker-sparql-pattern.c" 1000 } else { 1001 const gchar* _tmp65_; 1002 #line 84 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1003 _tmp65_ = self->object; 1004 #line 84 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1005 if (_tmp65_ != NULL) { 1006 #line 1005 "tracker-sparql-pattern.c" 1007 const gchar* _tmp66_; 1008 gint _tmp67_ = 0; 1009 gint object_id; 1010 TrackerDBInterface* _tmp68_ = NULL; 1011 TrackerDBInterface* _tmp69_; 1012 TrackerDBInterface* iface; 1013 TrackerDBInterface* _tmp70_; 1014 TrackerDBStatement* _tmp71_ = NULL; 1015 TrackerDBStatement* stmt; 1016 TrackerDBStatement* _tmp72_; 1017 gint _tmp73_; 1018 TrackerDBStatement* _tmp74_; 1019 TrackerDBCursor* _tmp75_ = NULL; 1020 TrackerDBCursor* cursor; 1021 gboolean first; 1022 TrackerDBCursor* _tmp76_; 1023 gboolean _tmp116_; 1024 #line 86 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1025 _tmp66_ = self->object; 1026 #line 86 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1027 _tmp67_ = tracker_data_query_resource_id (_tmp66_); 1028 #line 86 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1029 object_id = _tmp67_; 1030 #line 88 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1031 _tmp68_ = tracker_db_manager_get_db_interface (); 1032 #line 88 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1033 _tmp69_ = _g_object_ref0 (_tmp68_); 1034 #line 88 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1035 iface = _tmp69_; 1036 #line 89 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1037 _tmp70_ = iface; 1038 #line 89 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1039 _tmp71_ = tracker_db_interface_create_statement (_tmp70_, TRACKER_DB_STATEMENT_CACHE_TYPE_SELECT, &_inner_error_, "SELECT (SELECT Uri FROM Resource WHERE ID = \"rdf:type\") " "FROM \"rdfs:Resource_rdf:type\" WHERE ID = ?"); 1040 #line 89 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1041 stmt = _tmp71_; 1042 #line 89 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1043 if (_inner_error_ != NULL) { 1044 #line 89 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1045 _g_object_unref0 (iface); 1046 #line 89 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1047 _g_string_free0 (sql); 1048 #line 1047 "tracker-sparql-pattern.c" 1049 goto __catch0_g_error; 1050 } 1051 #line 92 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1052 _tmp72_ = stmt; 1053 #line 92 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1054 _tmp73_ = object_id; 1055 #line 92 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1056 tracker_db_statement_bind_int (_tmp72_, 0, _tmp73_); 1057 #line 93 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1058 _tmp74_ = stmt; 1059 #line 93 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1060 _tmp75_ = tracker_db_statement_start_cursor (_tmp74_, &_inner_error_); 1061 #line 93 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1062 cursor = _tmp75_; 1063 #line 93 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1064 if (_inner_error_ != NULL) { 1065 #line 93 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1066 _g_object_unref0 (stmt); 1067 #line 93 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1068 _g_object_unref0 (iface); 1069 #line 93 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1070 _g_string_free0 (sql); 1071 #line 1070 "tracker-sparql-pattern.c" 1072 goto __catch0_g_error; 1073 } 1074 #line 95 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1075 first = TRUE; 1076 #line 96 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1077 _tmp76_ = cursor; 1078 #line 96 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1079 if (_tmp76_ != NULL) { 1080 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1081 while (TRUE) { 1082 #line 1081 "tracker-sparql-pattern.c" 1083 TrackerDBCursor* _tmp77_; 1084 gboolean _tmp78_ = FALSE; 1085 gboolean _tmp79_; 1086 TrackerDBCursor* _tmp80_; 1087 const gchar* _tmp81_ = NULL; 1088 TrackerClass* _tmp82_ = NULL; 1089 TrackerClass* _tmp83_; 1090 TrackerClass* range; 1091 gint _tmp84_ = 0; 1092 TrackerProperty** _tmp85_ = NULL; 1093 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1094 _tmp77_ = cursor; 1095 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1096 _tmp78_ = tracker_sparql_cursor_next ((TrackerSparqlCursor*) _tmp77_, NULL, &_inner_error_); 1097 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1098 _tmp79_ = _tmp78_; 1099 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1100 if (_inner_error_ != NULL) { 1101 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1102 _g_object_unref0 (cursor); 1103 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1104 _g_object_unref0 (stmt); 1105 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1106 _g_object_unref0 (iface); 1107 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1108 _g_string_free0 (sql); 1109 #line 1108 "tracker-sparql-pattern.c" 1110 goto __catch0_g_error; 1111 } 1112 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1113 if (!_tmp79_) { 1114 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1115 break; 1116 #line 1115 "tracker-sparql-pattern.c" 1117 } 1118 #line 98 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1119 _tmp80_ = cursor; 1120 #line 98 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1121 _tmp81_ = tracker_sparql_cursor_get_string ((TrackerSparqlCursor*) _tmp80_, 0, NULL); 1122 #line 98 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1123 _tmp82_ = tracker_ontologies_get_class_by_uri (_tmp81_); 1124 #line 98 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1125 _tmp83_ = _g_object_ref0 (_tmp82_); 1126 #line 98 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1127 range = _tmp83_; 1128 #line 100 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1129 _tmp85_ = tracker_ontologies_get_properties (&_tmp84_); 1130 #line 1129 "tracker-sparql-pattern.c" 1131 { 1132 TrackerProperty** prop_collection = NULL; 1133 gint prop_collection_length1 = 0; 1134 gint _prop_collection_size_ = 0; 1135 gint prop_it = 0; 1136 #line 100 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1137 prop_collection = _tmp85_; 1138 #line 100 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1139 prop_collection_length1 = _tmp84_;
Value stored to 'prop_collection_length1' is never read
(emitted by clang-analyzer)

TODO: a detailed trace is available in the data model (not yet rendered in this report)

1140 #line 100 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1141 for (prop_it = 0; prop_it < _tmp84_; prop_it = prop_it + 1) { 1142 #line 1141 "tracker-sparql-pattern.c" 1143 TrackerProperty* _tmp86_; 1144 TrackerProperty* prop = NULL; 1145 #line 100 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1146 _tmp86_ = _g_object_ref0 (prop_collection[prop_it]); 1147 #line 100 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1148 prop = _tmp86_; 1149 #line 1148 "tracker-sparql-pattern.c" 1150 { 1151 TrackerProperty* _tmp87_; 1152 TrackerClass* _tmp88_; 1153 TrackerClass* _tmp89_; 1154 TrackerClass* _tmp90_; 1155 #line 101 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1156 _tmp87_ = prop; 1157 #line 101 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1158 _tmp88_ = tracker_property_get_range (_tmp87_); 1159 #line 101 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1160 _tmp89_ = _tmp88_; 1161 #line 101 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1162 _tmp90_ = range; 1163 #line 101 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1164 if (_tmp89_ == _tmp90_) { 1165 #line 1164 "tracker-sparql-pattern.c" 1166 gboolean _tmp91_; 1167 GString* _tmp93_; 1168 TrackerProperty* _tmp94_; 1169 const gchar* _tmp95_; 1170 const gchar* _tmp96_; 1171 GString* _tmp97_; 1172 TrackerProperty* _tmp98_; 1173 const gchar* _tmp99_; 1174 const gchar* _tmp100_; 1175 gchar* _tmp101_ = NULL; 1176 gchar* _tmp102_; 1177 TrackerProperty* _tmp103_; 1178 TrackerPropertyType _tmp104_; 1179 TrackerPropertyType _tmp105_; 1180 GString* _tmp106_; 1181 gboolean _tmp107_; 1182 GString* _tmp112_; 1183 TrackerProperty* _tmp113_; 1184 const gchar* _tmp114_; 1185 const gchar* _tmp115_; 1186 #line 102 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1187 _tmp91_ = first; 1188 #line 102 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1189 if (_tmp91_) { 1190 #line 103 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1191 first = FALSE; 1192 #line 1191 "tracker-sparql-pattern.c" 1193 } else { 1194 GString* _tmp92_; 1195 #line 105 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1196 _tmp92_ = sql; 1197 #line 105 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1198 g_string_append (_tmp92_, " UNION ALL "); 1199 #line 1198 "tracker-sparql-pattern.c" 1200 } 1201 #line 107 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1202 _tmp93_ = sql; 1203 #line 107 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1204 _tmp94_ = prop; 1205 #line 107 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1206 _tmp95_ = tracker_property_get_uri (_tmp94_); 1207 #line 107 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1208 _tmp96_ = _tmp95_; 1209 #line 107 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1210 g_string_append_printf (_tmp93_, "SELECT ID, (SELECT ID FROM Resource WHERE Uri = '%s') AS \"predicate\"" \ 1211 ", ", _tmp96_); 1212 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1213 _tmp97_ = sql; 1214 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1215 _tmp98_ = prop; 1216 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1217 _tmp99_ = tracker_property_get_name (_tmp98_); 1218 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1219 _tmp100_ = _tmp99_; 1220 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1221 _tmp101_ = g_strdup_printf ("\"%s\"", _tmp100_); 1222 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1223 _tmp102_ = _tmp101_; 1224 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1225 _tmp103_ = prop; 1226 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1227 _tmp104_ = tracker_property_get_data_type (_tmp103_); 1228 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1229 _tmp105_ = _tmp104_; 1230 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1231 tracker_sparql_expression_append_expression_as_string (_tmp97_, _tmp102_, _tmp105_); 1232 #line 109 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1233 _g_free0 (_tmp102_); 1234 #line 111 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1235 _tmp106_ = sql; 1236 #line 111 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1237 g_string_append (_tmp106_, " AS \"object\""); 1238 #line 112 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1239 _tmp107_ = self->return_graph; 1240 #line 112 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1241 if (_tmp107_) { 1242 #line 1240 "tracker-sparql-pattern.c" 1243 GString* _tmp108_; 1244 TrackerProperty* _tmp109_; 1245 const gchar* _tmp110_; 1246 const gchar* _tmp111_; 1247 #line 113 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1248 _tmp108_ = sql; 1249 #line 113 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1250 _tmp109_ = prop; 1251 #line 113 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1252 _tmp110_ = tracker_property_get_name (_tmp109_); 1253 #line 113 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1254 _tmp111_ = _tmp110_; 1255 #line 113 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1256 g_string_append_printf (_tmp108_, ", \"%s:graph\" AS \"graph\"", _tmp111_); 1257 #line 1255 "tracker-sparql-pattern.c" 1258 } 1259 #line 115 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1260 _tmp112_ = sql; 1261 #line 115 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1262 _tmp113_ = prop; 1263 #line 115 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1264 _tmp114_ = tracker_property_get_table_name (_tmp113_); 1265 #line 115 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1266 _tmp115_ = _tmp114_; 1267 #line 115 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1268 g_string_append_printf (_tmp112_, " FROM \"%s\"", _tmp115_); 1269 #line 1267 "tracker-sparql-pattern.c" 1270 } 1271 #line 100 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1272 _g_object_unref0 (prop); 1273 #line 1271 "tracker-sparql-pattern.c" 1274 } 1275 } 1276 } 1277 #line 97 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1278 _g_object_unref0 (range); 1279 #line 1277 "tracker-sparql-pattern.c" 1280 } 1281 } 1282 #line 121 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1283 _tmp116_ = first; 1284 #line 121 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1285 if (_tmp116_) { 1286 #line 1284 "tracker-sparql-pattern.c" 1287 GString* _tmp117_; 1288 #line 123 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1289 _tmp117_ = sql; 1290 #line 123 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1291 g_string_append (_tmp117_, "SELECT NULL AS ID, NULL AS \"predicate\", NULL AS \"object\", NULL AS " \ 1292 "\"graph\""); 1293 #line 1290 "tracker-sparql-pattern.c" 1294 } 1295 #line 84 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1296 _g_object_unref0 (cursor); 1297 #line 84 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1298 _g_object_unref0 (stmt); 1299 #line 84 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1300 _g_object_unref0 (iface); 1301 #line 1298 "tracker-sparql-pattern.c" 1302 } else { 1303 TrackerClass* _tmp118_; 1304 #line 125 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1305 _tmp118_ = self->domain; 1306 #line 125 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1307 if (_tmp118_ != NULL) { 1308 #line 1305 "tracker-sparql-pattern.c" 1309 gboolean first; 1310 gint _tmp119_ = 0; 1311 TrackerProperty** _tmp120_ = NULL; 1312 #line 127 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1313 first = TRUE; 1314 #line 128 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1315 _tmp120_ = tracker_ontologies_get_properties (&_tmp119_); 1316 #line 1313 "tracker-sparql-pattern.c" 1317 { 1318 TrackerProperty** prop_collection = NULL; 1319 gint prop_collection_length1 = 0; 1320 gint _prop_collection_size_ = 0; 1321 gint prop_it = 0; 1322 #line 128 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1323 prop_collection = _tmp120_; 1324 #line 128 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1325 prop_collection_length1 = _tmp119_;
Value stored to 'prop_collection_length1' is never read
(emitted by clang-analyzer)

TODO: a detailed trace is available in the data model (not yet rendered in this report)

1326 #line 128 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1327 for (prop_it = 0; prop_it < _tmp119_; prop_it = prop_it + 1) { 1328 #line 1325 "tracker-sparql-pattern.c" 1329 TrackerProperty* _tmp121_; 1330 TrackerProperty* prop = NULL; 1331 #line 128 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1332 _tmp121_ = _g_object_ref0 (prop_collection[prop_it]); 1333 #line 128 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1334 prop = _tmp121_; 1335 #line 1332 "tracker-sparql-pattern.c" 1336 { 1337 TrackerProperty* _tmp122_; 1338 TrackerClass* _tmp123_; 1339 TrackerClass* _tmp124_; 1340 TrackerClass* _tmp125_; 1341 #line 129 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1342 _tmp122_ = prop; 1343 #line 129 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1344 _tmp123_ = tracker_property_get_domain (_tmp122_); 1345 #line 129 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1346 _tmp124_ = _tmp123_; 1347 #line 129 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1348 _tmp125_ = self->domain; 1349 #line 129 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1350 if (_tmp124_ == _tmp125_) { 1351 #line 1348 "tracker-sparql-pattern.c" 1352 gboolean _tmp126_; 1353 GString* _tmp128_; 1354 TrackerProperty* _tmp129_; 1355 const gchar* _tmp130_; 1356 const gchar* _tmp131_; 1357 GString* _tmp132_; 1358 TrackerProperty* _tmp133_; 1359 const gchar* _tmp134_; 1360 const gchar* _tmp135_; 1361 gchar* _tmp136_ = NULL; 1362 gchar* _tmp137_; 1363 TrackerProperty* _tmp138_; 1364 TrackerPropertyType _tmp139_; 1365 TrackerPropertyType _tmp140_; 1366 GString* _tmp141_; 1367 gboolean _tmp142_; 1368 GString* _tmp147_; 1369 TrackerProperty* _tmp148_; 1370 const gchar* _tmp149_; 1371 const gchar* _tmp150_; 1372 #line 130 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1373 _tmp126_ = first; 1374 #line 130 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1375 if (_tmp126_) { 1376 #line 131 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1377 first = FALSE; 1378 #line 1375 "tracker-sparql-pattern.c" 1379 } else { 1380 GString* _tmp127_; 1381 #line 133 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1382 _tmp127_ = sql; 1383 #line 133 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1384 g_string_append (_tmp127_, " UNION ALL "); 1385 #line 1382 "tracker-sparql-pattern.c" 1386 } 1387 #line 135 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1388 _tmp128_ = sql; 1389 #line 135 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1390 _tmp129_ = prop; 1391 #line 135 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1392 _tmp130_ = tracker_property_get_uri (_tmp129_); 1393 #line 135 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala"
syntax error
(emitted by cppcheck)
1394 _tmp131_ = _tmp130_; 1395 #line 135 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1396 g_string_append_printf (_tmp128_, "SELECT ID, (SELECT ID FROM Resource WHERE Uri = '%s') AS \"predicate\"" \ 1397 ", ", _tmp131_); 1398 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1399 _tmp132_ = sql; 1400 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1401 _tmp133_ = prop; 1402 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1403 _tmp134_ = tracker_property_get_name (_tmp133_); 1404 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1405 _tmp135_ = _tmp134_; 1406 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1407 _tmp136_ = g_strdup_printf ("\"%s\"", _tmp135_); 1408 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1409 _tmp137_ = _tmp136_; 1410 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1411 _tmp138_ = prop; 1412 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1413 _tmp139_ = tracker_property_get_data_type (_tmp138_); 1414 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1415 _tmp140_ = _tmp139_; 1416 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1417 tracker_sparql_expression_append_expression_as_string (_tmp132_, _tmp137_, _tmp140_); 1418 #line 137 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1419 _g_free0 (_tmp137_); 1420 #line 139 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1421 _tmp141_ = sql; 1422 #line 139 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1423 g_string_append (_tmp141_, " AS \"object\""); 1424 #line 140 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1425 _tmp142_ = self->return_graph; 1426 #line 140 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1427 if (_tmp142_) { 1428 #line 1424 "tracker-sparql-pattern.c" 1429 GString* _tmp143_; 1430 TrackerProperty* _tmp144_; 1431 const gchar* _tmp145_; 1432 const gchar* _tmp146_; 1433 #line 141 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1434 _tmp143_ = sql; 1435 #line 141 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1436 _tmp144_ = prop; 1437 #line 141 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1438 _tmp145_ = tracker_property_get_name (_tmp144_); 1439 #line 141 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1440 _tmp146_ = _tmp145_; 1441 #line 141 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1442 g_string_append_printf (_tmp143_, ", \"%s:graph\" AS \"graph\"", _tmp146_); 1443 #line 1439 "tracker-sparql-pattern.c" 1444 } 1445 #line 143 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1446 _tmp147_ = sql; 1447 #line 143 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1448 _tmp148_ = prop; 1449 #line 143 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1450 _tmp149_ = tracker_property_get_table_name (_tmp148_); 1451 #line 143 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1452 _tmp150_ = _tmp149_; 1453 #line 143 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1454 g_string_append_printf (_tmp147_, " FROM \"%s\"", _tmp150_); 1455 #line 1451 "tracker-sparql-pattern.c" 1456 } 1457 #line 128 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1458 _g_object_unref0 (prop); 1459 #line 1455 "tracker-sparql-pattern.c" 1460 } 1461 } 1462 } 1463 } else { 1464 TrackerSparqlQuery* _tmp151_; 1465 GError* _tmp152_ = NULL; 1466 #line 148 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1467 _tmp151_ = query; 1468 #line 148 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1469 _tmp152_ = tracker_sparql_query_get_internal_error (_tmp151_, "Unrestricted predicate variables not supported"); 1470 #line 148 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1471 _inner_error_ = _tmp152_; 1472 #line 148 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1473 _g_string_free0 (sql); 1474 #line 1470 "tracker-sparql-pattern.c" 1475 goto __catch0_g_error; 1476 } 1477 } 1478 } 1479 #line 150 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1480 _tmp153_ = sql; 1481 #line 150 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1482 _tmp154_ = _tmp153_->str; 1483 #line 150 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1484 _tmp155_ = g_strdup (_tmp154_); 1485 #line 150 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1486 result = _tmp155_; 1487 #line 150 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1488 _g_string_free0 (sql); 1489 #line 150 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1490 return result; 1491 #line 1487 "tracker-sparql-pattern.c" 1492 } 1493 goto __finally0; 1494 __catch0_g_error: 1495 { 1496 GError* e = NULL; 1497 GError* _tmp156_; 1498 const gchar* _tmp157_; 1499 GError* _tmp158_; 1500 #line 30 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1501 e = _inner_error_; 1502 #line 30 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1503 _inner_error_ = NULL; 1504 #line 152 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1505 _tmp156_ = e; 1506 #line 152 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1507 _tmp157_ = _tmp156_->message; 1508 #line 152 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1509 _tmp158_ = g_error_new_literal (TRACKER_SPARQL_ERROR, TRACKER_SPARQL_ERROR_INTERNAL, _tmp157_); 1510 #line 152 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1511 _inner_error_ = _tmp158_; 1512 #line 152 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1513 _g_error_free0 (e); 1514 #line 1510 "tracker-sparql-pattern.c" 1515 goto __finally0; 1516 } 1517 __finally0: 1518 #line 30 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1519 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 1520 #line 30 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1521 g_propagate_error (error, _inner_error_); 1522 #line 30 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1523 return NULL; 1524 #line 1520 "tracker-sparql-pattern.c" 1525 } else { 1526 #line 30 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1527 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 1528 #line 30 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1529 g_clear_error (&_inner_error_); 1530 #line 30 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1531 return NULL; 1532 #line 1528 "tracker-sparql-pattern.c" 1533 } 1534 } 1535 1536 1537 TrackerSparqlPredicateVariable* tracker_sparql_predicate_variable_construct (GType object_type) { 1538 TrackerSparqlPredicateVariable * self = NULL; 1539 #line 22 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1540 self = (TrackerSparqlPredicateVariable*) g_object_new (object_type, NULL); 1541 #line 22 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1542 return self; 1543 #line 1539 "tracker-sparql-pattern.c" 1544 } 1545 1546 1547 TrackerSparqlPredicateVariable* tracker_sparql_predicate_variable_new (void) { 1548 #line 22 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1549 return tracker_sparql_predicate_variable_construct (TRACKER_SPARQL_TYPE_PREDICATE_VARIABLE); 1550 #line 1546 "tracker-sparql-pattern.c" 1551 } 1552 1553 1554 static void tracker_sparql_predicate_variable_class_init (TrackerSparqlPredicateVariableClass * klass) { 1555 #line 22 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1556 tracker_sparql_predicate_variable_parent_class = g_type_class_peek_parent (klass); 1557 #line 22 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1558 G_OBJECT_CLASS (klass)->finalize = tracker_sparql_predicate_variable_finalize; 1559 #line 1555 "tracker-sparql-pattern.c" 1560 } 1561 1562 1563 static void tracker_sparql_predicate_variable_instance_init (TrackerSparqlPredicateVariable * self) { 1564 } 1565 1566 1567 static void tracker_sparql_predicate_variable_finalize (GObject* obj) { 1568 TrackerSparqlPredicateVariable * self; 1569 #line 22 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1570 self = G_TYPE_CHECK_INSTANCE_CAST (obj, TRACKER_SPARQL_TYPE_PREDICATE_VARIABLE, TrackerSparqlPredicateVariable); 1571 #line 23 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1572 _g_free0 (self->subject); 1573 #line 24 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1574 _g_free0 (self->object); 1575 #line 27 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1576 _g_object_unref0 (self->domain); 1577 #line 22 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1578 G_OBJECT_CLASS (tracker_sparql_predicate_variable_parent_class)->finalize (obj); 1579 #line 1575 "tracker-sparql-pattern.c" 1580 } 1581 1582 1583 GType tracker_sparql_predicate_variable_get_type (void) { 1584 static volatile gsize tracker_sparql_predicate_variable_type_id__volatile = 0; 1585 if (g_once_init_enter (&tracker_sparql_predicate_variable_type_id__volatile)) { 1586 static const GTypeInfo g_define_type_info = { sizeof (TrackerSparqlPredicateVariableClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) tracker_sparql_predicate_variable_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (TrackerSparqlPredicateVariable), 0, (GInstanceInitFunc) tracker_sparql_predicate_variable_instance_init, NULL }; 1587 GType tracker_sparql_predicate_variable_type_id; 1588 tracker_sparql_predicate_variable_type_id = g_type_register_static (G_TYPE_OBJECT, "TrackerSparqlPredicateVariable", &g_define_type_info, 0); 1589 g_once_init_leave (&tracker_sparql_predicate_variable_type_id__volatile, tracker_sparql_predicate_variable_type_id); 1590 } 1591 return tracker_sparql_predicate_variable_type_id__volatile; 1592 } 1593 1594 1595 TrackerSparqlPattern* tracker_sparql_pattern_construct (GType object_type, TrackerSparqlQuery* query) { 1596 TrackerSparqlPattern * self = NULL; 1597 TrackerSparqlQuery* _tmp0_; 1598 TrackerSparqlQuery* _tmp1_; 1599 TrackerSparqlExpression* _tmp2_; 1600 #line 177 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1601 g_return_val_if_fail (query != NULL, NULL); 1602 #line 177 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1603 self = (TrackerSparqlPattern*) g_object_new (object_type, NULL); 1604 #line 178 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1605 _tmp0_ = query; 1606 #line 178 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1607 self->priv->query = _tmp0_; 1608 #line 179 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1609 _tmp1_ = query; 1610 #line 179 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1611 _tmp2_ = _tmp1_->expression; 1612 #line 179 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1613 self->priv->expression = _tmp2_; 1614 #line 177 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1615 return self; 1616 #line 1612 "tracker-sparql-pattern.c" 1617 } 1618 1619 1620 TrackerSparqlPattern* tracker_sparql_pattern_new (TrackerSparqlQuery* query) { 1621 #line 177 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1622 return tracker_sparql_pattern_construct (TRACKER_SPARQL_TYPE_PATTERN, query); 1623 #line 1619 "tracker-sparql-pattern.c" 1624 } 1625 1626 1627 static inline gboolean tracker_sparql_pattern_next (TrackerSparqlPattern* self, GError** error) { 1628 gboolean result = FALSE; 1629 TrackerSparqlQuery* _tmp0_; 1630 gboolean _tmp1_ = FALSE; 1631 gboolean _tmp2_; 1632 GError * _inner_error_ = NULL; 1633 #line 187 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1634 g_return_val_if_fail (self != NULL, FALSE); 1635 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1636 _tmp0_ = self->priv->query; 1637 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1638 _tmp1_ = tracker_sparql_query_next (_tmp0_, &_inner_error_); 1639 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1640 _tmp2_ = _tmp1_; 1641 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1642 if (_inner_error_ != NULL) { 1643 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1644 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 1645 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1646 g_propagate_error (error, _inner_error_); 1647 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1648 return FALSE; 1649 #line 1645 "tracker-sparql-pattern.c" 1650 } else { 1651 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1652 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 1653 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1654 g_clear_error (&_inner_error_); 1655 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1656 return FALSE; 1657 #line 1653 "tracker-sparql-pattern.c" 1658 } 1659 } 1660 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1661 result = _tmp2_; 1662 #line 188 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1663 return result; 1664 #line 1660 "tracker-sparql-pattern.c" 1665 } 1666 1667 1668 static inline TrackerSparqlTokenType tracker_sparql_pattern_current (TrackerSparqlPattern* self) { 1669 TrackerSparqlTokenType result = 0; 1670 TrackerSparqlQuery* _tmp0_; 1671 TrackerSparqlTokenType _tmp1_ = 0; 1672 #line 191 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1673 g_return_val_if_fail (self != NULL, 0); 1674 #line 192 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1675 _tmp0_ = self->priv->query; 1676 #line 192 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1677 _tmp1_ = tracker_sparql_query_current (_tmp0_); 1678 #line 192 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1679 result = _tmp1_; 1680 #line 192 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1681 return result; 1682 #line 1678 "tracker-sparql-pattern.c" 1683 } 1684 1685 1686 static inline gboolean tracker_sparql_pattern_accept (TrackerSparqlPattern* self, TrackerSparqlTokenType type, GError** error) { 1687 gboolean result = FALSE; 1688 TrackerSparqlQuery* _tmp0_; 1689 TrackerSparqlTokenType _tmp1_; 1690 gboolean _tmp2_ = FALSE; 1691 gboolean _tmp3_; 1692 GError * _inner_error_ = NULL; 1693 #line 195 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1694 g_return_val_if_fail (self != NULL, FALSE); 1695 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1696 _tmp0_ = self->priv->query; 1697 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1698 _tmp1_ = type; 1699 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1700 _tmp2_ = tracker_sparql_query_accept (_tmp0_, _tmp1_, &_inner_error_); 1701 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1702 _tmp3_ = _tmp2_; 1703 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1704 if (_inner_error_ != NULL) { 1705 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1706 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 1707 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1708 g_propagate_error (error, _inner_error_); 1709 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1710 return FALSE; 1711 #line 1707 "tracker-sparql-pattern.c" 1712 } else { 1713 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1714 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 1715 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1716 g_clear_error (&_inner_error_); 1717 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1718 return FALSE; 1719 #line 1715 "tracker-sparql-pattern.c" 1720 } 1721 } 1722 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1723 result = _tmp3_; 1724 #line 196 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1725 return result; 1726 #line 1722 "tracker-sparql-pattern.c" 1727 } 1728 1729 1730 static GError* tracker_sparql_pattern_get_error (TrackerSparqlPattern* self, const gchar* msg) { 1731 GError* result = NULL; 1732 TrackerSparqlQuery* _tmp0_; 1733 const gchar* _tmp1_; 1734 GError* _tmp2_ = NULL; 1735 #line 199 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1736 g_return_val_if_fail (self != NULL, NULL); 1737 #line 199 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1738 g_return_val_if_fail (msg != NULL, NULL); 1739 #line 200 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1740 _tmp0_ = self->priv->query; 1741 #line 200 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1742 _tmp1_ = msg; 1743 #line 200 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1744 _tmp2_ = tracker_sparql_query_get_error (_tmp0_, _tmp1_); 1745 #line 200 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1746 result = _tmp2_; 1747 #line 200 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1748 return result; 1749 #line 1745 "tracker-sparql-pattern.c" 1750 } 1751 1752 1753 static gboolean tracker_sparql_pattern_expect (TrackerSparqlPattern* self, TrackerSparqlTokenType type, GError** error) { 1754 gboolean result = FALSE; 1755 TrackerSparqlQuery* _tmp0_; 1756 TrackerSparqlTokenType _tmp1_; 1757 gboolean _tmp2_ = FALSE; 1758 gboolean _tmp3_; 1759 GError * _inner_error_ = NULL; 1760 #line 203 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1761 g_return_val_if_fail (self != NULL, FALSE); 1762 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1763 _tmp0_ = self->priv->query; 1764 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1765 _tmp1_ = type; 1766 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1767 _tmp2_ = tracker_sparql_query_expect (_tmp0_, _tmp1_, &_inner_error_); 1768 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1769 _tmp3_ = _tmp2_; 1770 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1771 if (_inner_error_ != NULL) { 1772 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1773 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 1774 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1775 g_propagate_error (error, _inner_error_); 1776 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1777 return FALSE; 1778 #line 1774 "tracker-sparql-pattern.c" 1779 } else { 1780 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1781 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 1782 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1783 g_clear_error (&_inner_error_); 1784 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1785 return FALSE; 1786 #line 1782 "tracker-sparql-pattern.c" 1787 } 1788 } 1789 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1790 result = _tmp3_; 1791 #line 204 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1792 return result; 1793 #line 1789 "tracker-sparql-pattern.c" 1794 } 1795 1796 1797 static void tracker_sparql_pattern_get_location (TrackerSparqlPattern* self, TrackerSourceLocation* result) { 1798 TrackerSparqlQuery* _tmp0_; 1799 TrackerSourceLocation _tmp1_ = {0}; 1800 #line 207 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1801 g_return_if_fail (self != NULL); 1802 #line 208 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1803 _tmp0_ = self->priv->query; 1804 #line 208 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1805 tracker_sparql_query_get_location (_tmp0_, &_tmp1_); 1806 #line 208 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1807 *result = _tmp1_; 1808 #line 208 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1809 return; 1810 #line 1806 "tracker-sparql-pattern.c" 1811 } 1812 1813 1814 static void tracker_sparql_pattern_set_location (TrackerSparqlPattern* self, TrackerSourceLocation* location) { 1815 TrackerSparqlQuery* _tmp0_; 1816 TrackerSourceLocation _tmp1_; 1817 #line 211 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1818 g_return_if_fail (self != NULL); 1819 #line 211 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1820 g_return_if_fail (location != NULL); 1821 #line 212 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1822 _tmp0_ = self->priv->query; 1823 #line 212 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1824 _tmp1_ = *location; 1825 #line 212 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1826 tracker_sparql_query_set_location (_tmp0_, &_tmp1_); 1827 #line 1823 "tracker-sparql-pattern.c" 1828 } 1829 1830 1831 static gchar* tracker_sparql_pattern_get_last_string (TrackerSparqlPattern* self, gint strip) { 1832 gchar* result = NULL; 1833 TrackerSparqlQuery* _tmp0_; 1834 gint _tmp1_; 1835 gchar* _tmp2_ = NULL; 1836 #line 215 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1837 g_return_val_if_fail (self != NULL, NULL); 1838 #line 216 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1839 _tmp0_ = self->priv->query; 1840 #line 216 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1841 _tmp1_ = strip; 1842 #line 216 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1843 _tmp2_ = tracker_sparql_query_get_last_string (_tmp0_, _tmp1_); 1844 #line 216 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1845 result = _tmp2_; 1846 #line 216 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1847 return result; 1848 #line 1844 "tracker-sparql-pattern.c" 1849 } 1850 1851 1852 static void _g_object_unref0_ (gpointer var) { 1853 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1854 (var == NULL) ? NULL : (var = (g_object_unref (var), NULL)); 1855 #line 1851 "tracker-sparql-pattern.c" 1856 } 1857 1858 1859 static void _g_list_free__g_object_unref0_ (GList* self) { 1860 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1861 g_list_foreach (self, (GFunc) _g_object_unref0_, NULL); 1862 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1863 g_list_free (self); 1864 #line 1860 "tracker-sparql-pattern.c" 1865 } 1866 1867 1868 static void _vala_array_add5 (TrackerPropertyType** array, int* length, int* size, TrackerPropertyType value) { 1869 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1870 if ((*length) == (*size)) { 1871 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1872 *size = (*size) ? (2 * (*size)) : 4; 1873 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1874 *array = g_renew (TrackerPropertyType, *array, *size); 1875 #line 1871 "tracker-sparql-pattern.c" 1876 } 1877 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1878 (*array)[(*length)++] = value; 1879 #line 1875 "tracker-sparql-pattern.c" 1880 } 1881 1882 1883 static void _vala_array_add6 (gchar*** array, int* length, int* size, gchar* value) { 1884 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1885 if ((*length) == (*size)) { 1886 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1887 *size = (*size) ? (2 * (*size)) : 4; 1888 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1889 *array = g_renew (gchar*, *array, (*size) + 1); 1890 #line 1886 "tracker-sparql-pattern.c" 1891 } 1892 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1893 (*array)[(*length)++] = value; 1894 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1895 (*array)[*length] = NULL; 1896 #line 1892 "tracker-sparql-pattern.c" 1897 } 1898 1899 1900 static void _vala_array_add7 (TrackerPropertyType** array, int* length, int* size, TrackerPropertyType value) { 1901 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1902 if ((*length) == (*size)) { 1903 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1904 *size = (*size) ? (2 * (*size)) : 4; 1905 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1906 *array = g_renew (TrackerPropertyType, *array, *size); 1907 #line 1903 "tracker-sparql-pattern.c" 1908 } 1909 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1910 (*array)[(*length)++] = value; 1911 #line 1907 "tracker-sparql-pattern.c" 1912 } 1913 1914 1915 TrackerSparqlSelectContext* tracker_sparql_pattern_translate_select (TrackerSparqlPattern* self, GString* sql, gboolean subquery, gboolean scalar_subquery, GError** error) { 1916 TrackerSparqlSelectContext* result = NULL; 1917 TrackerSparqlSelectContext* _result_ = NULL; 1918 gboolean _tmp0_; 1919 TrackerSparqlSelectContext* _tmp9_; 1920 TrackerPropertyType type; 1921 GString* _tmp10_; 1922 GString* pattern_sql; 1923 TrackerSparqlQuery* _tmp11_; 1924 GList* _tmp12_; 1925 GList* old_bindings; 1926 GString* _tmp13_; 1927 gboolean _tmp14_ = FALSE; 1928 gboolean _tmp15_; 1929 TrackerSourceLocation _tmp19_ = {0}; 1930 TrackerSourceLocation select_variables_location; 1931 TrackerSparqlExpression* _tmp20_; 1932 gboolean _tmp21_ = FALSE; 1933 gboolean _tmp22_; 1934 GString* _tmp23_; 1935 TrackerSparqlContext* _tmp24_ = NULL; 1936 TrackerSparqlContext* pattern; 1937 TrackerSparqlContext* _tmp25_; 1938 GHashTable* _tmp26_; 1939 GList* _tmp27_ = NULL; 1940 TrackerSourceLocation _tmp33_ = {0}; 1941 TrackerSourceLocation after_where; 1942 TrackerSourceLocation _tmp34_; 1943 TrackerSparqlContext* _tmp35_; 1944 TrackerSparqlContext* _tmp36_; 1945 GHashTable* _tmp37_; 1946 GList* _tmp38_ = NULL; 1947 TrackerSparqlQuery* _tmp48_; 1948 GList* _tmp49_; 1949 GList* where_bindings; 1950 TrackerSparqlQuery* _tmp50_; 1951 GList* _tmp51_; 1952 gboolean first; 1953 gboolean _tmp52_ = FALSE; 1954 gboolean _tmp53_; 1955 gboolean _tmp105_ = FALSE; 1956 gboolean _tmp106_; 1957 gboolean _tmp108_; 1958 GList* _tmp117_; 1959 gboolean _tmp122_; 1960 GString* _tmp124_; 1961 GString* _tmp125_; 1962 GString* _tmp126_; 1963 const gchar* _tmp127_; 1964 GString* _tmp128_; 1965 TrackerSourceLocation _tmp129_; 1966 gboolean _tmp130_ = FALSE; 1967 gboolean _tmp131_; 1968 gboolean _tmp163_ = FALSE; 1969 gboolean _tmp164_; 1970 gint limit; 1971 gint offset; 1972 gboolean _tmp185_ = FALSE; 1973 gboolean _tmp186_; 1974 gint _tmp205_; 1975 gboolean _tmp235_ = FALSE; 1976 gboolean _tmp236_ = FALSE; 1977 gboolean _tmp237_; 1978 gboolean _tmp239_; 1979 gboolean _tmp241_; 1980 TrackerSparqlContext* _tmp258_; 1981 TrackerSparqlContext* _tmp259_; 1982 TrackerSparqlContext* _tmp260_; 1983 TrackerSparqlSelectContext* _tmp261_; 1984 TrackerPropertyType _tmp262_; 1985 GError * _inner_error_ = NULL; 1986 #line 244 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1987 g_return_val_if_fail (self != NULL, NULL); 1988 #line 244 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1989 g_return_val_if_fail (sql != NULL, NULL); 1990 #line 247 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1991 _tmp0_ = scalar_subquery; 1992 #line 247 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 1993 if (_tmp0_) { 1994 #line 1990 "tracker-sparql-pattern.c" 1995 TrackerSparqlQuery* _tmp1_; 1996 TrackerSparqlContext* _tmp2_; 1997 TrackerSparqlContext* _tmp3_; 1998 TrackerSparqlSelectContext* _tmp4_; 1999 #line 248 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2000 _tmp1_ = self->priv->query; 2001 #line 248 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2002 _tmp2_ = tracker_sparql_pattern_get_context (self); 2003 #line 248 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2004 _tmp3_ = _tmp2_; 2005 #line 248 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2006 _tmp4_ = tracker_sparql_select_context_new_subquery (_tmp1_, _tmp3_); 2007 #line 248 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2008 _tracker_sparql_context_unref0 (_result_); 2009 #line 248 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2010 _result_ = _tmp4_; 2011 #line 2007 "tracker-sparql-pattern.c" 2012 } else { 2013 TrackerSparqlQuery* _tmp5_; 2014 TrackerSparqlContext* _tmp6_; 2015 TrackerSparqlContext* _tmp7_; 2016 TrackerSparqlSelectContext* _tmp8_; 2017 #line 250 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2018 _tmp5_ = self->priv->query; 2019 #line 250 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2020 _tmp6_ = tracker_sparql_pattern_get_context (self); 2021 #line 250 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2022 _tmp7_ = _tmp6_; 2023 #line 250 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2024 _tmp8_ = tracker_sparql_select_context_new (_tmp5_, _tmp7_); 2025 #line 250 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2026 _tracker_sparql_context_unref0 (_result_); 2027 #line 250 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2028 _result_ = _tmp8_; 2029 #line 2025 "tracker-sparql-pattern.c" 2030 } 2031 #line 252 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2032 _tmp9_ = _result_; 2033 #line 252 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2034 tracker_sparql_pattern_set_context (self, (TrackerSparqlContext*) _tmp9_); 2035 #line 253 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2036 type = TRACKER_PROPERTY_TYPE_UNKNOWN; 2037 #line 255 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2038 _tmp10_ = g_string_new (""); 2039 #line 255 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2040 pattern_sql = _tmp10_; 2041 #line 256 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2042 _tmp11_ = self->priv->query; 2043 #line 256 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2044 _tmp12_ = _tmp11_->bindings; 2045 #line 256 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2046 _tmp11_->bindings = NULL; 2047 #line 256 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2048 old_bindings = _tmp12_; 2049 #line 258 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2050 _tmp13_ = sql; 2051 #line 258 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2052 g_string_append (_tmp13_, "SELECT "); 2053 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2054 tracker_sparql_pattern_expect (self, TRACKER_SPARQL_TOKEN_TYPE_SELECT, &_inner_error_); 2055 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2056 if (_inner_error_ != NULL) { 2057 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2058 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2059 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2060 g_propagate_error (error, _inner_error_); 2061 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2062 __g_list_free__g_object_unref0_0 (old_bindings); 2063 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2064 _g_string_free0 (pattern_sql); 2065 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2066 _tracker_sparql_context_unref0 (_result_); 2067 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2068 return NULL; 2069 #line 2065 "tracker-sparql-pattern.c" 2070 } else { 2071 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2072 __g_list_free__g_object_unref0_0 (old_bindings); 2073 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2074 _g_string_free0 (pattern_sql); 2075 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2076 _tracker_sparql_context_unref0 (_result_); 2077 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2078 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2079 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2080 g_clear_error (&_inner_error_); 2081 #line 260 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2082 return NULL; 2083 #line 2079 "tracker-sparql-pattern.c" 2084 } 2085 } 2086 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2087 _tmp14_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_DISTINCT, &_inner_error_); 2088 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2089 _tmp15_ = _tmp14_; 2090 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2091 if (_inner_error_ != NULL) { 2092 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2093 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2094 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2095 g_propagate_error (error, _inner_error_); 2096 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2097 __g_list_free__g_object_unref0_0 (old_bindings); 2098 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2099 _g_string_free0 (pattern_sql); 2100 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2101 _tracker_sparql_context_unref0 (_result_); 2102 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2103 return NULL; 2104 #line 2100 "tracker-sparql-pattern.c" 2105 } else { 2106 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2107 __g_list_free__g_object_unref0_0 (old_bindings); 2108 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2109 _g_string_free0 (pattern_sql); 2110 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2111 _tracker_sparql_context_unref0 (_result_); 2112 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2113 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2114 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2115 g_clear_error (&_inner_error_); 2116 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2117 return NULL; 2118 #line 2114 "tracker-sparql-pattern.c" 2119 } 2120 } 2121 #line 262 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2122 if (_tmp15_) { 2123 #line 2119 "tracker-sparql-pattern.c" 2124 GString* _tmp16_; 2125 #line 263 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2126 _tmp16_ = sql; 2127 #line 263 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2128 g_string_append (_tmp16_, "DISTINCT "); 2129 #line 2125 "tracker-sparql-pattern.c" 2130 } else { 2131 gboolean _tmp17_ = FALSE; 2132 gboolean _tmp18_; 2133 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2134 _tmp17_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_REDUCED, &_inner_error_); 2135 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2136 _tmp18_ = _tmp17_; 2137 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2138 if (_inner_error_ != NULL) { 2139 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2140 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2141 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2142 g_propagate_error (error, _inner_error_); 2143 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2144 __g_list_free__g_object_unref0_0 (old_bindings); 2145 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2146 _g_string_free0 (pattern_sql); 2147 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2148 _tracker_sparql_context_unref0 (_result_); 2149 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2150 return NULL; 2151 #line 2147 "tracker-sparql-pattern.c" 2152 } else { 2153 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2154 __g_list_free__g_object_unref0_0 (old_bindings); 2155 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2156 _g_string_free0 (pattern_sql); 2157 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2158 _tracker_sparql_context_unref0 (_result_); 2159 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2160 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2161 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2162 g_clear_error (&_inner_error_); 2163 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2164 return NULL; 2165 #line 2161 "tracker-sparql-pattern.c" 2166 } 2167 } 2168 #line 264 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2169 if (_tmp18_) { 2170 #line 2166 "tracker-sparql-pattern.c" 2171 } 2172 } 2173 #line 268 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2174 tracker_sparql_pattern_get_location (self, &_tmp19_); 2175 #line 268 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2176 select_variables_location = _tmp19_; 2177 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2178 _tmp20_ = self->priv->expression; 2179 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2180 tracker_sparql_expression_skip_select_variables (_tmp20_, &_inner_error_); 2181 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2182 if (_inner_error_ != NULL) { 2183 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2184 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2185 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2186 g_propagate_error (error, _inner_error_); 2187 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2188 __g_list_free__g_object_unref0_0 (old_bindings); 2189 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2190 _g_string_free0 (pattern_sql); 2191 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2192 _tracker_sparql_context_unref0 (_result_); 2193 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2194 return NULL; 2195 #line 2191 "tracker-sparql-pattern.c" 2196 } else { 2197 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2198 __g_list_free__g_object_unref0_0 (old_bindings); 2199 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2200 _g_string_free0 (pattern_sql); 2201 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2202 _tracker_sparql_context_unref0 (_result_); 2203 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2204 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2205 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2206 g_clear_error (&_inner_error_); 2207 #line 269 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2208 return NULL; 2209 #line 2205 "tracker-sparql-pattern.c" 2210 } 2211 } 2212 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2213 _tmp21_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_FROM, &_inner_error_); 2214 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2215 _tmp22_ = _tmp21_; 2216 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2217 if (_inner_error_ != NULL) { 2218 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2219 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2220 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2221 g_propagate_error (error, _inner_error_); 2222 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2223 __g_list_free__g_object_unref0_0 (old_bindings); 2224 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2225 _g_string_free0 (pattern_sql); 2226 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2227 _tracker_sparql_context_unref0 (_result_); 2228 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2229 return NULL; 2230 #line 2226 "tracker-sparql-pattern.c" 2231 } else { 2232 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2233 __g_list_free__g_object_unref0_0 (old_bindings); 2234 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2235 _g_string_free0 (pattern_sql); 2236 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2237 _tracker_sparql_context_unref0 (_result_); 2238 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2239 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2240 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2241 g_clear_error (&_inner_error_); 2242 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2243 return NULL; 2244 #line 2240 "tracker-sparql-pattern.c" 2245 } 2246 } 2247 #line 271 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2248 if (_tmp22_) { 2249 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2250 tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_NAMED, &_inner_error_); 2251 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2252 if (_inner_error_ != NULL) { 2253 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2254 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2255 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2256 g_propagate_error (error, _inner_error_); 2257 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2258 __g_list_free__g_object_unref0_0 (old_bindings); 2259 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2260 _g_string_free0 (pattern_sql); 2261 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2262 _tracker_sparql_context_unref0 (_result_); 2263 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2264 return NULL; 2265 #line 2261 "tracker-sparql-pattern.c" 2266 } else { 2267 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2268 __g_list_free__g_object_unref0_0 (old_bindings); 2269 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2270 _g_string_free0 (pattern_sql); 2271 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2272 _tracker_sparql_context_unref0 (_result_); 2273 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2274 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2275 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2276 g_clear_error (&_inner_error_); 2277 #line 272 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2278 return NULL; 2279 #line 2275 "tracker-sparql-pattern.c" 2280 } 2281 } 2282 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2283 tracker_sparql_pattern_expect (self, TRACKER_SPARQL_TOKEN_TYPE_IRI_REF, &_inner_error_); 2284 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2285 if (_inner_error_ != NULL) { 2286 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2287 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2288 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2289 g_propagate_error (error, _inner_error_); 2290 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2291 __g_list_free__g_object_unref0_0 (old_bindings); 2292 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2293 _g_string_free0 (pattern_sql); 2294 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2295 _tracker_sparql_context_unref0 (_result_); 2296 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2297 return NULL; 2298 #line 2294 "tracker-sparql-pattern.c" 2299 } else { 2300 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2301 __g_list_free__g_object_unref0_0 (old_bindings); 2302 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2303 _g_string_free0 (pattern_sql); 2304 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2305 _tracker_sparql_context_unref0 (_result_); 2306 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2307 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2308 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2309 g_clear_error (&_inner_error_); 2310 #line 273 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2311 return NULL; 2312 #line 2308 "tracker-sparql-pattern.c" 2313 } 2314 } 2315 } 2316 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2317 tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_WHERE, &_inner_error_); 2318 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2319 if (_inner_error_ != NULL) { 2320 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2321 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2322 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2323 g_propagate_error (error, _inner_error_); 2324 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2325 __g_list_free__g_object_unref0_0 (old_bindings); 2326 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2327 _g_string_free0 (pattern_sql); 2328 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2329 _tracker_sparql_context_unref0 (_result_); 2330 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2331 return NULL; 2332 #line 2328 "tracker-sparql-pattern.c" 2333 } else { 2334 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2335 __g_list_free__g_object_unref0_0 (old_bindings); 2336 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2337 _g_string_free0 (pattern_sql); 2338 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2339 _tracker_sparql_context_unref0 (_result_); 2340 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2341 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2342 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2343 g_clear_error (&_inner_error_); 2344 #line 276 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2345 return NULL; 2346 #line 2342 "tracker-sparql-pattern.c" 2347 } 2348 } 2349 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2350 _tmp23_ = pattern_sql; 2351 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2352 _tmp24_ = tracker_sparql_pattern_translate_group_graph_pattern (self, _tmp23_, &_inner_error_); 2353 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2354 pattern = _tmp24_; 2355 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2356 if (_inner_error_ != NULL) { 2357 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2358 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2359 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2360 g_propagate_error (error, _inner_error_); 2361 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2362 __g_list_free__g_object_unref0_0 (old_bindings); 2363 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2364 _g_string_free0 (pattern_sql); 2365 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2366 _tracker_sparql_context_unref0 (_result_); 2367 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2368 return NULL; 2369 #line 2365 "tracker-sparql-pattern.c" 2370 } else { 2371 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2372 __g_list_free__g_object_unref0_0 (old_bindings); 2373 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2374 _g_string_free0 (pattern_sql); 2375 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2376 _tracker_sparql_context_unref0 (_result_); 2377 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2378 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2379 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2380 g_clear_error (&_inner_error_); 2381 #line 278 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2382 return NULL; 2383 #line 2379 "tracker-sparql-pattern.c" 2384 } 2385 } 2386 #line 279 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2387 _tmp25_ = pattern; 2388 #line 279 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2389 _tmp26_ = _tmp25_->var_set; 2390 #line 279 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2391 _tmp27_ = g_hash_table_get_keys (_tmp26_); 2392 #line 2388 "tracker-sparql-pattern.c" 2393 { 2394 GList* key_collection = NULL; 2395 GList* key_it = NULL; 2396 #line 279 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2397 key_collection = _tmp27_; 2398 #line 279 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2399 for (key_it = key_collection; key_it != NULL; key_it = key_it->next) { 2400 #line 2396 "tracker-sparql-pattern.c" 2401 TrackerSparqlVariable* key = NULL; 2402 #line 279 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2403 key = (TrackerSparqlVariable*) key_it->data; 2404 #line 2400 "tracker-sparql-pattern.c" 2405 { 2406 TrackerSparqlContext* _tmp28_; 2407 TrackerSparqlContext* _tmp29_; 2408 GHashTable* _tmp30_; 2409 TrackerSparqlVariable* _tmp31_; 2410 TrackerSparqlVariable* _tmp32_; 2411 #line 280 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2412 _tmp28_ = tracker_sparql_pattern_get_context (self); 2413 #line 280 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2414 _tmp29_ = _tmp28_; 2415 #line 280 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2416 _tmp30_ = _tmp29_->var_set; 2417 #line 280 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2418 _tmp31_ = key; 2419 #line 280 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2420 _tmp32_ = _g_object_ref0 (_tmp31_); 2421 #line 280 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2422 g_hash_table_insert (_tmp30_, _tmp32_, (gpointer) ((gintptr) ((gint) TRACKER_SPARQL_VARIABLE_STATE_BOUND))); 2423 #line 2419 "tracker-sparql-pattern.c" 2424 } 2425 } 2426 #line 279 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2427 _g_list_free0 (key_collection); 2428 #line 2424 "tracker-sparql-pattern.c" 2429 } 2430 #line 284 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2431 tracker_sparql_pattern_get_location (self, &_tmp33_); 2432 #line 284 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2433 after_where = _tmp33_; 2434 #line 285 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2435 _tmp34_ = select_variables_location; 2436 #line 285 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2437 tracker_sparql_pattern_set_location (self, &_tmp34_); 2438 #line 288 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2439 _tmp35_ = tracker_sparql_pattern_get_context (self); 2440 #line 288 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2441 _tmp36_ = _tmp35_; 2442 #line 288 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2443 _tmp37_ = _tmp36_->var_set; 2444 #line 288 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2445 _tmp38_ = g_hash_table_get_keys (_tmp37_); 2446 #line 2442 "tracker-sparql-pattern.c" 2447 { 2448 GList* variable_collection = NULL; 2449 GList* variable_it = NULL; 2450 #line 288 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2451 variable_collection = _tmp38_; 2452 #line 288 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2453 for (variable_it = variable_collection; variable_it != NULL; variable_it = variable_it->next) { 2454 #line 2450 "tracker-sparql-pattern.c" 2455 TrackerSparqlVariable* variable = NULL; 2456 #line 288 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2457 variable = (TrackerSparqlVariable*) variable_it->data; 2458 #line 2454 "tracker-sparql-pattern.c" 2459 { 2460 TrackerSparqlVariable* _tmp39_; 2461 TrackerSparqlVariableBinding* _tmp40_; 2462 #line 289 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2463 _tmp39_ = variable; 2464 #line 289 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2465 _tmp40_ = _tmp39_->binding; 2466 #line 289 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2467 if (_tmp40_ == NULL) { 2468 #line 2464 "tracker-sparql-pattern.c" 2469 TrackerSparqlVariable* _tmp41_; 2470 const gchar* _tmp42_; 2471 const gchar* _tmp43_; 2472 gchar* _tmp44_ = NULL; 2473 gchar* _tmp45_; 2474 GError* _tmp46_ = NULL; 2475 GError* _tmp47_; 2476 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2477 _tmp41_ = variable; 2478 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2479 _tmp42_ = tracker_sparql_variable_get_name (_tmp41_); 2480 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2481 _tmp43_ = _tmp42_; 2482 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2483 _tmp44_ = g_strdup_printf ("use of undefined variable `%s'", _tmp43_); 2484 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2485 _tmp45_ = _tmp44_; 2486 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2487 _tmp46_ = tracker_sparql_pattern_get_error (self, _tmp45_); 2488 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2489 _tmp47_ = _tmp46_; 2490 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2491 _g_free0 (_tmp45_); 2492 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2493 _inner_error_ = _tmp47_; 2494 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2495 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2496 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2497 g_propagate_error (error, _inner_error_); 2498 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2499 _g_list_free0 (variable_collection); 2500 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2501 _tracker_sparql_context_unref0 (pattern); 2502 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2503 __g_list_free__g_object_unref0_0 (old_bindings); 2504 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2505 _g_string_free0 (pattern_sql); 2506 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2507 _tracker_sparql_context_unref0 (_result_); 2508 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2509 return NULL; 2510 #line 2506 "tracker-sparql-pattern.c" 2511 } else { 2512 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2513 _g_list_free0 (variable_collection); 2514 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2515 _tracker_sparql_context_unref0 (pattern); 2516 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2517 __g_list_free__g_object_unref0_0 (old_bindings); 2518 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2519 _g_string_free0 (pattern_sql); 2520 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2521 _tracker_sparql_context_unref0 (_result_); 2522 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2523 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2524 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2525 g_clear_error (&_inner_error_); 2526 #line 290 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2527 return NULL; 2528 #line 2524 "tracker-sparql-pattern.c" 2529 } 2530 } 2531 } 2532 } 2533 #line 288 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2534 _g_list_free0 (variable_collection); 2535 #line 2531 "tracker-sparql-pattern.c" 2536 } 2537 #line 294 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2538 _tmp48_ = self->priv->query; 2539 #line 294 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2540 _tmp49_ = _tmp48_->bindings; 2541 #line 294 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2542 _tmp48_->bindings = NULL; 2543 #line 294 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2544 where_bindings = _tmp49_; 2545 #line 295 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2546 _tmp50_ = self->priv->query; 2547 #line 295 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2548 _tmp51_ = old_bindings; 2549 #line 295 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2550 old_bindings = NULL; 2551 #line 295 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2552 __g_list_free__g_object_unref0_0 (_tmp50_->bindings); 2553 #line 295 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2554 _tmp50_->bindings = _tmp51_; 2555 #line 297 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2556 first = TRUE; 2557 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2558 _tmp52_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_STAR, &_inner_error_); 2559 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2560 _tmp53_ = _tmp52_; 2561 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2562 if (_inner_error_ != NULL) { 2563 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2564 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2565 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2566 g_propagate_error (error, _inner_error_); 2567 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2568 __g_list_free__g_object_unref0_0 (where_bindings); 2569 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2570 _tracker_sparql_context_unref0 (pattern); 2571 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2572 __g_list_free__g_object_unref0_0 (old_bindings); 2573 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2574 _g_string_free0 (pattern_sql); 2575 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2576 _tracker_sparql_context_unref0 (_result_); 2577 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2578 return NULL; 2579 #line 2575 "tracker-sparql-pattern.c" 2580 } else { 2581 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2582 __g_list_free__g_object_unref0_0 (where_bindings); 2583 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2584 _tracker_sparql_context_unref0 (pattern); 2585 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2586 __g_list_free__g_object_unref0_0 (old_bindings); 2587 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2588 _g_string_free0 (pattern_sql); 2589 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2590 _tracker_sparql_context_unref0 (_result_); 2591 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2592 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2593 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2594 g_clear_error (&_inner_error_); 2595 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2596 return NULL; 2597 #line 2593 "tracker-sparql-pattern.c" 2598 } 2599 } 2600 #line 298 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2601 if (_tmp53_) { 2602 #line 2598 "tracker-sparql-pattern.c" 2603 TrackerSparqlContext* _tmp54_; 2604 TrackerSparqlContext* _tmp55_; 2605 GHashTable* _tmp56_; 2606 GList* _tmp57_ = NULL; 2607 #line 299 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2608 _tmp54_ = tracker_sparql_pattern_get_context (self); 2609 #line 299 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2610 _tmp55_ = _tmp54_; 2611 #line 299 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2612 _tmp56_ = _tmp55_->var_set; 2613 #line 299 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2614 _tmp57_ = g_hash_table_get_keys (_tmp56_); 2615 #line 2611 "tracker-sparql-pattern.c" 2616 { 2617 GList* variable_collection = NULL; 2618 GList* variable_it = NULL; 2619 #line 299 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2620 variable_collection = _tmp57_; 2621 #line 299 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2622 for (variable_it = variable_collection; variable_it != NULL; variable_it = variable_it->next) { 2623 #line 2619 "tracker-sparql-pattern.c" 2624 TrackerSparqlVariable* variable = NULL; 2625 #line 299 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2626 variable = (TrackerSparqlVariable*) variable_it->data; 2627 #line 2623 "tracker-sparql-pattern.c" 2628 { 2629 gboolean _tmp58_; 2630 gboolean _tmp60_; 2631 TrackerSparqlSelectContext* _tmp76_; 2632 TrackerSparqlSelectContext* _tmp77_; 2633 TrackerPropertyType* _tmp78_; 2634 gint _tmp78__length1; 2635 TrackerSparqlVariable* _tmp79_; 2636 TrackerSparqlVariableBinding* _tmp80_;
variable '_tmp84__length1' set but not used
(emitted by gcc)
2637 TrackerPropertyType _tmp81_; 2638 TrackerSparqlSelectContext* _tmp82_; 2639 TrackerSparqlSelectContext* _tmp83_; 2640 gchar** _tmp84_; 2641 gint _tmp84__length1; 2642 TrackerSparqlVariable* _tmp85_; 2643 const gchar* _tmp86_; 2644 const gchar* _tmp87_; 2645 gchar* _tmp88_; 2646 #line 300 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2647 _tmp58_ = first; 2648 #line 300 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2649 if (!_tmp58_) { 2650 #line 2646 "tracker-sparql-pattern.c" 2651 GString* _tmp59_; 2652 #line 301 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2653 _tmp59_ = sql; 2654 #line 301 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2655 g_string_append (_tmp59_, ", "); 2656 #line 2652 "tracker-sparql-pattern.c" 2657 } else { 2658 #line 303 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2659 first = FALSE; 2660 #line 2656 "tracker-sparql-pattern.c" 2661 } 2662 #line 305 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2663 _tmp60_ = subquery; 2664 #line 305 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2665 if (_tmp60_) { 2666 #line 2662 "tracker-sparql-pattern.c" 2667 GString* _tmp61_; 2668 TrackerSparqlVariable* _tmp62_; 2669 const gchar* _tmp63_; 2670 const gchar* _tmp64_; 2671 #line 307 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2672 _tmp61_ = sql; 2673 #line 307 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2674 _tmp62_ = variable; 2675 #line 307 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2676 _tmp63_ = tracker_sparql_variable_get_sql_expression (_tmp62_); 2677 #line 307 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2678 _tmp64_ = _tmp63_; 2679 #line 307 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2680 g_string_append (_tmp61_, _tmp64_); 2681 #line 2677 "tracker-sparql-pattern.c" 2682 } else { 2683 GString* _tmp65_; 2684 TrackerSparqlVariable* _tmp66_; 2685 const gchar* _tmp67_; 2686 const gchar* _tmp68_; 2687 TrackerSparqlVariable* _tmp69_; 2688 TrackerSparqlVariableBinding* _tmp70_; 2689 TrackerPropertyType _tmp71_; 2690 GString* _tmp72_; 2691 TrackerSparqlVariable* _tmp73_; 2692 const gchar* _tmp74_; 2693 const gchar* _tmp75_; 2694 #line 309 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2695 _tmp65_ = sql; 2696 #line 309 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2697 _tmp66_ = variable; 2698 #line 309 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2699 _tmp67_ = tracker_sparql_variable_get_sql_expression (_tmp66_); 2700 #line 309 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2701 _tmp68_ = _tmp67_; 2702 #line 309 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2703 _tmp69_ = variable; 2704 #line 309 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2705 _tmp70_ = _tmp69_->binding; 2706 #line 309 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2707 _tmp71_ = ((TrackerSparqlDataBinding*) _tmp70_)->data_type; 2708 #line 309 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2709 tracker_sparql_expression_append_expression_as_string (_tmp65_, _tmp68_, _tmp71_); 2710 #line 310 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2711 _tmp72_ = sql; 2712 #line 310 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2713 _tmp73_ = variable; 2714 #line 310 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2715 _tmp74_ = tracker_sparql_variable_get_name (_tmp73_); 2716 #line 310 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2717 _tmp75_ = _tmp74_; 2718 #line 310 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2719 g_string_append_printf (_tmp72_, " AS \"%s\"", _tmp75_); 2720 #line 2716 "tracker-sparql-pattern.c" 2721 } 2722 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2723 _tmp76_ = _result_; 2724 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2725 _tmp77_ = _result_; 2726 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2727 _tmp78_ = _tmp77_->types;
Value stored to '_tmp78_' is never read
(emitted by clang-analyzer)

TODO: a detailed trace is available in the data model (not yet rendered in this report)

2728 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2729 _tmp78__length1 = _tmp77_->types_length1;
Value stored to '_tmp78__length1' is never read
(emitted by clang-analyzer)

TODO: a detailed trace is available in the data model (not yet rendered in this report)

2730 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2731 _tmp79_ = variable; 2732 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2733 _tmp80_ = _tmp79_->binding; 2734 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2735 _tmp81_ = ((TrackerSparqlDataBinding*) _tmp80_)->data_type; 2736 #line 312 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2737 _vala_array_add5 (&_tmp76_->types, &_tmp76_->types_length1, &_tmp76_->_types_size_, _tmp81_); 2738 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2739 _tmp82_ = _result_; 2740 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2741 _tmp83_ = _result_; 2742 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2743 _tmp84_ = _tmp83_->variable_names;
Value stored to '_tmp84_' is never read
(emitted by clang-analyzer)

TODO: a detailed trace is available in the data model (not yet rendered in this report)

2744 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2745 _tmp84__length1 = _tmp83_->variable_names_length1;
Value stored to '_tmp84__length1' is never read
(emitted by clang-analyzer)

TODO: a detailed trace is available in the data model (not yet rendered in this report)

2746 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2747 _tmp85_ = variable; 2748 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2749 _tmp86_ = tracker_sparql_variable_get_name (_tmp85_); 2750 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2751 _tmp87_ = _tmp86_; 2752 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2753 _tmp88_ = g_strdup (_tmp87_); 2754 #line 313 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2755 _vala_array_add6 (&_tmp82_->variable_names, &_tmp82_->variable_names_length1, &_tmp82_->_variable_names_size_, _tmp88_); 2756 #line 2752 "tracker-sparql-pattern.c" 2757 } 2758 } 2759 #line 299 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2760 _g_list_free0 (variable_collection); 2761 #line 2757 "tracker-sparql-pattern.c" 2762 } 2763 } else { 2764 { 2765 gint i; 2766 #line 316 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2767 i = 0; 2768 #line 2764 "tracker-sparql-pattern.c" 2769 { 2770 gboolean _tmp89_; 2771 #line 316 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2772 _tmp89_ = TRUE; 2773 #line 316 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2774 while (TRUE) { 2775 #line 2771 "tracker-sparql-pattern.c" 2776 gboolean _tmp90_; 2777 gint _tmp92_; 2778 TrackerSparqlExpression* _tmp94_; 2779 GString* _tmp95_; 2780 gboolean _tmp96_; 2781 gint _tmp97_; 2782 TrackerPropertyType _tmp98_ = 0; 2783 TrackerPropertyType _tmp99_; 2784 TrackerSparqlSelectContext* _tmp100_; 2785 TrackerSparqlSelectContext* _tmp101_; 2786 TrackerPropertyType* _tmp102_; 2787 gint _tmp102__length1; 2788 TrackerPropertyType _tmp103_; 2789 TrackerSparqlTokenType _tmp104_ = 0; 2790 #line 316 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2791 _tmp90_ = _tmp89_; 2792 #line 316 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2793 if (!_tmp90_) { 2794 #line 2790 "tracker-sparql-pattern.c" 2795 gint _tmp91_; 2796 #line 316 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2797 _tmp91_ = i; 2798 #line 316 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2799 i = _tmp91_ + 1; 2800 #line 2796 "tracker-sparql-pattern.c" 2801 } 2802 #line 316 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2803 _tmp89_ = FALSE; 2804 #line 317 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2805 first = FALSE; 2806 #line 319 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2807 _tmp92_ = i; 2808 #line 319 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2809 if (_tmp92_ > 0) { 2810 #line 2806 "tracker-sparql-pattern.c" 2811 GString* _tmp93_; 2812 #line 320 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2813 _tmp93_ = sql; 2814 #line 320 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2815 g_string_append (_tmp93_, ", "); 2816 #line 2812 "tracker-sparql-pattern.c" 2817 } 2818 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2819 _tmp94_ = self->priv->expression; 2820 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2821 _tmp95_ = sql; 2822 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2823 _tmp96_ = subquery; 2824 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2825 _tmp97_ = i; 2826 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2827 _tmp98_ = tracker_sparql_expression_translate_select_expression (_tmp94_, _tmp95_, _tmp96_, _tmp97_, &_inner_error_); 2828 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2829 _tmp99_ = _tmp98_; 2830 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2831 if (_inner_error_ != NULL) { 2832 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2833 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 2834 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2835 g_propagate_error (error, _inner_error_); 2836 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2837 __g_list_free__g_object_unref0_0 (where_bindings); 2838 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2839 _tracker_sparql_context_unref0 (pattern); 2840 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2841 __g_list_free__g_object_unref0_0 (old_bindings); 2842 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2843 _g_string_free0 (pattern_sql); 2844 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2845 _tracker_sparql_context_unref0 (_result_); 2846 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2847 return NULL; 2848 #line 2844 "tracker-sparql-pattern.c" 2849 } else { 2850 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2851 __g_list_free__g_object_unref0_0 (where_bindings); 2852 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2853 _tracker_sparql_context_unref0 (pattern); 2854 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2855 __g_list_free__g_object_unref0_0 (old_bindings); 2856 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2857 _g_string_free0 (pattern_sql); 2858 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2859 _tracker_sparql_context_unref0 (_result_); 2860 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2861 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 2862 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2863 g_clear_error (&_inner_error_); 2864 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2865 return NULL; 2866 #line 2862 "tracker-sparql-pattern.c" 2867 } 2868 } 2869 #line 323 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2870 type = _tmp99_; 2871 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2872 _tmp100_ = _result_; 2873 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2874 _tmp101_ = _result_; 2875 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2876 _tmp102_ = _tmp101_->types;
Value stored to '_tmp102_' is never read
(emitted by clang-analyzer)

TODO: a detailed trace is available in the data model (not yet rendered in this report)

2877 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2878 _tmp102__length1 = _tmp101_->types_length1;
Value stored to '_tmp102__length1' is never read
(emitted by clang-analyzer)

TODO: a detailed trace is available in the data model (not yet rendered in this report)

2879 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2880 _tmp103_ = type; 2881 #line 324 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2882 _vala_array_add7 (&_tmp100_->types, &_tmp100_->types_length1, &_tmp100_->_types_size_, _tmp103_); 2883 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2884 _tmp104_ = tracker_sparql_pattern_current (self); 2885 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2886 switch (_tmp104_) { 2887 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2888 case TRACKER_SPARQL_TOKEN_TYPE_FROM: 2889 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2890 case TRACKER_SPARQL_TOKEN_TYPE_WHERE: 2891 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2892 case TRACKER_SPARQL_TOKEN_TYPE_OPEN_BRACE: 2893 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2894 case TRACKER_SPARQL_TOKEN_TYPE_GROUP: 2895 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2896 case TRACKER_SPARQL_TOKEN_TYPE_ORDER: 2897 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2898 case TRACKER_SPARQL_TOKEN_TYPE_LIMIT: 2899 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2900 case TRACKER_SPARQL_TOKEN_TYPE_OFFSET: 2901 #line 326 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2902 case TRACKER_SPARQL_TOKEN_TYPE_EOF: 2903 #line 2899 "tracker-sparql-pattern.c" 2904 { 2905 #line 335 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2906 break; 2907 #line 2903 "tracker-sparql-pattern.c" 2908 } 2909 default: 2910 { 2911 #line 337 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2912 continue; 2913 #line 2909 "tracker-sparql-pattern.c" 2914 } 2915 } 2916 #line 339 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2917 break; 2918 #line 2914 "tracker-sparql-pattern.c" 2919 } 2920 } 2921 } 2922 } 2923 #line 343 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2924 _tmp106_ = self->queries_fts_data; 2925 #line 343 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2926 if (_tmp106_) { 2927 #line 2923 "tracker-sparql-pattern.c" 2928 TrackerSparqlVariable* _tmp107_; 2929 #line 343 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2930 _tmp107_ = self->fts_subject; 2931 #line 343 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2932 _tmp105_ = _tmp107_ != NULL; 2933 #line 2929 "tracker-sparql-pattern.c" 2934 } else { 2935 #line 343 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2936 _tmp105_ = FALSE; 2937 #line 2933 "tracker-sparql-pattern.c" 2938 } 2939 #line 343 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2940 _tmp108_ = _tmp105_; 2941 #line 343 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2942 if (_tmp108_) { 2943 #line 2939 "tracker-sparql-pattern.c" 2944 gboolean _tmp109_; 2945 GString* _tmp111_; 2946 TrackerSparqlVariable* _tmp112_; 2947 const gchar* _tmp113_; 2948 const gchar* _tmp114_; 2949 gchar* _tmp115_ = NULL; 2950 gchar* _tmp116_; 2951 #line 345 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2952 _tmp109_ = first; 2953 #line 345 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2954 if (!_tmp109_) { 2955 #line 2951 "tracker-sparql-pattern.c" 2956 GString* _tmp110_; 2957 #line 346 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2958 _tmp110_ = sql; 2959 #line 346 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2960 g_string_append (_tmp110_, ", "); 2961 #line 2957 "tracker-sparql-pattern.c" 2962 } else { 2963 #line 348 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2964 first = FALSE; 2965 #line 2961 "tracker-sparql-pattern.c" 2966 } 2967 #line 351 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2968 _tmp111_ = sql; 2969 #line 351 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2970 _tmp112_ = self->fts_subject; 2971 #line 351 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2972 _tmp113_ = tracker_sparql_variable_get_sql_expression (_tmp112_); 2973 #line 351 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2974 _tmp114_ = _tmp113_; 2975 #line 351 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2976 _tmp115_ = g_strdup_printf ("%s AS docid ", _tmp114_); 2977 #line 351 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2978 _tmp116_ = _tmp115_; 2979 #line 351 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2980 g_string_append (_tmp111_, _tmp116_); 2981 #line 351 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2982 _g_free0 (_tmp116_); 2983 #line 2979 "tracker-sparql-pattern.c" 2984 } 2985 #line 355 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2986 _tmp117_ = where_bindings; 2987 #line 2983 "tracker-sparql-pattern.c" 2988 { 2989 GList* binding_collection = NULL; 2990 GList* binding_it = NULL; 2991 #line 355 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2992 binding_collection = _tmp117_; 2993 #line 355 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2994 for (binding_it = binding_collection; binding_it != NULL; binding_it = binding_it->next) { 2995 #line 2991 "tracker-sparql-pattern.c" 2996 TrackerSparqlLiteralBinding* _tmp118_; 2997 TrackerSparqlLiteralBinding* binding = NULL; 2998 #line 355 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 2999 _tmp118_ = _g_object_ref0 ((TrackerSparqlLiteralBinding*) binding_it->data); 3000 #line 355 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3001 binding = _tmp118_; 3002 #line 2998 "tracker-sparql-pattern.c" 3003 { 3004 TrackerSparqlQuery* _tmp119_; 3005 TrackerSparqlLiteralBinding* _tmp120_; 3006 TrackerSparqlLiteralBinding* _tmp121_; 3007 #line 356 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3008 _tmp119_ = self->priv->query; 3009 #line 356 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3010 _tmp120_ = binding; 3011 #line 356 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3012 _tmp121_ = _g_object_ref0 (_tmp120_); 3013 #line 356 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3014 _tmp119_->bindings = g_list_append (_tmp119_->bindings, _tmp121_); 3015 #line 355 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3016 _g_object_unref0 (binding); 3017 #line 3013 "tracker-sparql-pattern.c" 3018 } 3019 } 3020 } 3021 #line 359 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3022 _tmp122_ = first; 3023 #line 359 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3024 if (_tmp122_) { 3025 #line 3021 "tracker-sparql-pattern.c" 3026 GString* _tmp123_; 3027 #line 360 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3028 _tmp123_ = sql; 3029 #line 360 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3030 g_string_append (_tmp123_, "NULL"); 3031 #line 3027 "tracker-sparql-pattern.c" 3032 } 3033 #line 364 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3034 _tmp124_ = sql; 3035 #line 364 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3036 g_string_append (_tmp124_, " FROM ("); 3037 #line 365 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3038 _tmp125_ = sql; 3039 #line 365 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3040 _tmp126_ = pattern_sql; 3041 #line 365 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3042 _tmp127_ = _tmp126_->str; 3043 #line 365 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3044 g_string_append (_tmp125_, _tmp127_); 3045 #line 366 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3046 _tmp128_ = sql; 3047 #line 366 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3048 g_string_append (_tmp128_, ")"); 3049 #line 368 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3050 _tmp129_ = after_where; 3051 #line 368 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3052 tracker_sparql_pattern_set_location (self, &_tmp129_); 3053 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3054 _tmp130_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_GROUP, &_inner_error_); 3055 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3056 _tmp131_ = _tmp130_; 3057 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3058 if (_inner_error_ != NULL) { 3059 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3060 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3061 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3062 g_propagate_error (error, _inner_error_); 3063 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3064 __g_list_free__g_object_unref0_0 (where_bindings); 3065 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3066 _tracker_sparql_context_unref0 (pattern); 3067 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3068 __g_list_free__g_object_unref0_0 (old_bindings); 3069 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3070 _g_string_free0 (pattern_sql); 3071 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3072 _tracker_sparql_context_unref0 (_result_); 3073 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3074 return NULL; 3075 #line 3071 "tracker-sparql-pattern.c" 3076 } else { 3077 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3078 __g_list_free__g_object_unref0_0 (where_bindings); 3079 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3080 _tracker_sparql_context_unref0 (pattern); 3081 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3082 __g_list_free__g_object_unref0_0 (old_bindings); 3083 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3084 _g_string_free0 (pattern_sql); 3085 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3086 _tracker_sparql_context_unref0 (_result_); 3087 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3088 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3089 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3090 g_clear_error (&_inner_error_); 3091 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3092 return NULL; 3093 #line 3089 "tracker-sparql-pattern.c" 3094 } 3095 } 3096 #line 370 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3097 if (_tmp131_) { 3098 #line 3094 "tracker-sparql-pattern.c" 3099 GString* _tmp132_; 3100 gboolean first_group; 3101 gboolean _tmp158_ = FALSE; 3102 gboolean _tmp159_; 3103 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3104 tracker_sparql_pattern_expect (self, TRACKER_SPARQL_TOKEN_TYPE_BY, &_inner_error_); 3105 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3106 if (_inner_error_ != NULL) { 3107 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3108 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3109 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3110 g_propagate_error (error, _inner_error_); 3111 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3112 __g_list_free__g_object_unref0_0 (where_bindings); 3113 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3114 _tracker_sparql_context_unref0 (pattern); 3115 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3116 __g_list_free__g_object_unref0_0 (old_bindings); 3117 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3118 _g_string_free0 (pattern_sql); 3119 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3120 _tracker_sparql_context_unref0 (_result_); 3121 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3122 return NULL; 3123 #line 3119 "tracker-sparql-pattern.c" 3124 } else { 3125 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3126 __g_list_free__g_object_unref0_0 (where_bindings); 3127 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3128 _tracker_sparql_context_unref0 (pattern); 3129 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3130 __g_list_free__g_object_unref0_0 (old_bindings); 3131 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3132 _g_string_free0 (pattern_sql); 3133 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3134 _tracker_sparql_context_unref0 (_result_); 3135 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3136 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3137 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3138 g_clear_error (&_inner_error_); 3139 #line 371 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3140 return NULL; 3141 #line 3137 "tracker-sparql-pattern.c" 3142 } 3143 } 3144 #line 372 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3145 _tmp132_ = sql; 3146 #line 372 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3147 g_string_append (_tmp132_, " GROUP BY "); 3148 #line 373 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3149 first_group = TRUE; 3150 #line 3146 "tracker-sparql-pattern.c" 3151 { 3152 gboolean _tmp133_; 3153 #line 374 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3154 _tmp133_ = TRUE; 3155 #line 374 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3156 while (TRUE) { 3157 #line 3153 "tracker-sparql-pattern.c" 3158 gboolean _tmp134_; 3159 gboolean _tmp154_; 3160 TrackerSparqlExpression* _tmp156_; 3161 GString* _tmp157_; 3162 #line 374 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3163 _tmp134_ = _tmp133_; 3164 #line 374 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3165 if (!_tmp134_) { 3166 #line 3162 "tracker-sparql-pattern.c" 3167 gboolean _tmp135_ = FALSE; 3168 gboolean _tmp136_ = FALSE; 3169 gboolean _tmp137_ = FALSE; 3170 gboolean _tmp138_ = FALSE; 3171 gboolean _tmp139_ = FALSE; 3172 gboolean _tmp140_ = FALSE; 3173 TrackerSparqlTokenType _tmp141_ = 0; 3174 gboolean _tmp143_; 3175 gboolean _tmp145_; 3176 gboolean _tmp147_; 3177 gboolean _tmp149_; 3178 gboolean _tmp151_; 3179 gboolean _tmp153_; 3180 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3181 _tmp141_ = tracker_sparql_pattern_current (self); 3182 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3183 if (_tmp141_ != TRACKER_SPARQL_TOKEN_TYPE_HAVING) { 3184 #line 3180 "tracker-sparql-pattern.c" 3185 TrackerSparqlTokenType _tmp142_ = 0; 3186 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3187 _tmp142_ = tracker_sparql_pattern_current (self); 3188 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3189 _tmp140_ = _tmp142_ != TRACKER_SPARQL_TOKEN_TYPE_ORDER; 3190 #line 3186 "tracker-sparql-pattern.c" 3191 } else { 3192 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3193 _tmp140_ = FALSE; 3194 #line 3190 "tracker-sparql-pattern.c" 3195 } 3196 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3197 _tmp143_ = _tmp140_; 3198 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3199 if (_tmp143_) { 3200 #line 3196 "tracker-sparql-pattern.c" 3201 TrackerSparqlTokenType _tmp144_ = 0; 3202 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3203 _tmp144_ = tracker_sparql_pattern_current (self); 3204 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3205 _tmp139_ = _tmp144_ != TRACKER_SPARQL_TOKEN_TYPE_LIMIT; 3206 #line 3202 "tracker-sparql-pattern.c" 3207 } else { 3208 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3209 _tmp139_ = FALSE; 3210 #line 3206 "tracker-sparql-pattern.c" 3211 } 3212 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3213 _tmp145_ = _tmp139_; 3214 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3215 if (_tmp145_) { 3216 #line 3212 "tracker-sparql-pattern.c" 3217 TrackerSparqlTokenType _tmp146_ = 0; 3218 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3219 _tmp146_ = tracker_sparql_pattern_current (self); 3220 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3221 _tmp138_ = _tmp146_ != TRACKER_SPARQL_TOKEN_TYPE_OFFSET; 3222 #line 3218 "tracker-sparql-pattern.c" 3223 } else { 3224 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3225 _tmp138_ = FALSE; 3226 #line 3222 "tracker-sparql-pattern.c" 3227 } 3228 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3229 _tmp147_ = _tmp138_; 3230 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3231 if (_tmp147_) { 3232 #line 3228 "tracker-sparql-pattern.c" 3233 TrackerSparqlTokenType _tmp148_ = 0; 3234 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3235 _tmp148_ = tracker_sparql_pattern_current (self); 3236 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3237 _tmp137_ = _tmp148_ != TRACKER_SPARQL_TOKEN_TYPE_CLOSE_BRACE; 3238 #line 3234 "tracker-sparql-pattern.c" 3239 } else { 3240 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3241 _tmp137_ = FALSE; 3242 #line 3238 "tracker-sparql-pattern.c" 3243 } 3244 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3245 _tmp149_ = _tmp137_; 3246 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3247 if (_tmp149_) { 3248 #line 3244 "tracker-sparql-pattern.c" 3249 TrackerSparqlTokenType _tmp150_ = 0; 3250 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3251 _tmp150_ = tracker_sparql_pattern_current (self); 3252 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3253 _tmp136_ = _tmp150_ != TRACKER_SPARQL_TOKEN_TYPE_CLOSE_PARENS; 3254 #line 3250 "tracker-sparql-pattern.c" 3255 } else { 3256 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3257 _tmp136_ = FALSE; 3258 #line 3254 "tracker-sparql-pattern.c" 3259 } 3260 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3261 _tmp151_ = _tmp136_; 3262 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3263 if (_tmp151_) { 3264 #line 3260 "tracker-sparql-pattern.c" 3265 TrackerSparqlTokenType _tmp152_ = 0; 3266 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3267 _tmp152_ = tracker_sparql_pattern_current (self); 3268 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3269 _tmp135_ = _tmp152_ != TRACKER_SPARQL_TOKEN_TYPE_EOF; 3270 #line 3266 "tracker-sparql-pattern.c" 3271 } else { 3272 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3273 _tmp135_ = FALSE; 3274 #line 3270 "tracker-sparql-pattern.c" 3275 } 3276 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3277 _tmp153_ = _tmp135_; 3278 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3279 if (!_tmp153_) { 3280 #line 381 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3281 break; 3282 #line 3278 "tracker-sparql-pattern.c" 3283 } 3284 } 3285 #line 374 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3286 _tmp133_ = FALSE; 3287 #line 375 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3288 _tmp154_ = first_group; 3289 #line 375 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3290 if (_tmp154_) { 3291 #line 376 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3292 first_group = FALSE; 3293 #line 3289 "tracker-sparql-pattern.c" 3294 } else { 3295 GString* _tmp155_; 3296 #line 378 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3297 _tmp155_ = sql; 3298 #line 378 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3299 g_string_append (_tmp155_, ", "); 3300 #line 3296 "tracker-sparql-pattern.c" 3301 } 3302 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3303 _tmp156_ = self->priv->expression; 3304 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3305 _tmp157_ = sql; 3306 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3307 tracker_sparql_expression_translate_expression (_tmp156_, _tmp157_, &_inner_error_); 3308 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3309 if (_inner_error_ != NULL) { 3310 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3311 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3312 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3313 g_propagate_error (error, _inner_error_); 3314 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3315 __g_list_free__g_object_unref0_0 (where_bindings); 3316 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3317 _tracker_sparql_context_unref0 (pattern); 3318 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3319 __g_list_free__g_object_unref0_0 (old_bindings); 3320 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3321 _g_string_free0 (pattern_sql); 3322 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3323 _tracker_sparql_context_unref0 (_result_); 3324 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3325 return NULL; 3326 #line 3322 "tracker-sparql-pattern.c" 3327 } else { 3328 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3329 __g_list_free__g_object_unref0_0 (where_bindings); 3330 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3331 _tracker_sparql_context_unref0 (pattern); 3332 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3333 __g_list_free__g_object_unref0_0 (old_bindings); 3334 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3335 _g_string_free0 (pattern_sql); 3336 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3337 _tracker_sparql_context_unref0 (_result_); 3338 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3339 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3340 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3341 g_clear_error (&_inner_error_); 3342 #line 380 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3343 return NULL; 3344 #line 3340 "tracker-sparql-pattern.c" 3345 } 3346 } 3347 } 3348 } 3349 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3350 _tmp158_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_HAVING, &_inner_error_); 3351 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3352 _tmp159_ = _tmp158_; 3353 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3354 if (_inner_error_ != NULL) { 3355 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3356 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3357 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3358 g_propagate_error (error, _inner_error_); 3359 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3360 __g_list_free__g_object_unref0_0 (where_bindings); 3361 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3362 _tracker_sparql_context_unref0 (pattern); 3363 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3364 __g_list_free__g_object_unref0_0 (old_bindings); 3365 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3366 _g_string_free0 (pattern_sql); 3367 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3368 _tracker_sparql_context_unref0 (_result_); 3369 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3370 return NULL; 3371 #line 3367 "tracker-sparql-pattern.c" 3372 } else { 3373 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3374 __g_list_free__g_object_unref0_0 (where_bindings); 3375 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3376 _tracker_sparql_context_unref0 (pattern); 3377 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3378 __g_list_free__g_object_unref0_0 (old_bindings); 3379 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3380 _g_string_free0 (pattern_sql); 3381 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3382 _tracker_sparql_context_unref0 (_result_); 3383 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3384 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3385 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3386 g_clear_error (&_inner_error_); 3387 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3388 return NULL; 3389 #line 3385 "tracker-sparql-pattern.c" 3390 } 3391 } 3392 #line 383 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3393 if (_tmp159_) { 3394 #line 3390 "tracker-sparql-pattern.c" 3395 GString* _tmp160_; 3396 TrackerSparqlExpression* _tmp161_; 3397 GString* _tmp162_; 3398 #line 384 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3399 _tmp160_ = sql; 3400 #line 384 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3401 g_string_append (_tmp160_, " HAVING "); 3402 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3403 _tmp161_ = self->priv->expression; 3404 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3405 _tmp162_ = sql; 3406 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3407 tracker_sparql_expression_translate_constraint (_tmp161_, _tmp162_, &_inner_error_); 3408 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3409 if (_inner_error_ != NULL) { 3410 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3411 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3412 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3413 g_propagate_error (error, _inner_error_); 3414 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3415 __g_list_free__g_object_unref0_0 (where_bindings); 3416 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3417 _tracker_sparql_context_unref0 (pattern); 3418 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3419 __g_list_free__g_object_unref0_0 (old_bindings); 3420 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3421 _g_string_free0 (pattern_sql); 3422 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3423 _tracker_sparql_context_unref0 (_result_); 3424 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3425 return NULL; 3426 #line 3422 "tracker-sparql-pattern.c" 3427 } else { 3428 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3429 __g_list_free__g_object_unref0_0 (where_bindings); 3430 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3431 _tracker_sparql_context_unref0 (pattern); 3432 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3433 __g_list_free__g_object_unref0_0 (old_bindings); 3434 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3435 _g_string_free0 (pattern_sql); 3436 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3437 _tracker_sparql_context_unref0 (_result_); 3438 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3439 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3440 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3441 g_clear_error (&_inner_error_); 3442 #line 385 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3443 return NULL; 3444 #line 3440 "tracker-sparql-pattern.c" 3445 } 3446 } 3447 } 3448 } 3449 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3450 _tmp163_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_ORDER, &_inner_error_); 3451 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3452 _tmp164_ = _tmp163_; 3453 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3454 if (_inner_error_ != NULL) { 3455 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3456 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3457 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3458 g_propagate_error (error, _inner_error_); 3459 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3460 __g_list_free__g_object_unref0_0 (where_bindings); 3461 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3462 _tracker_sparql_context_unref0 (pattern); 3463 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3464 __g_list_free__g_object_unref0_0 (old_bindings); 3465 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3466 _g_string_free0 (pattern_sql); 3467 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3468 _tracker_sparql_context_unref0 (_result_); 3469 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3470 return NULL; 3471 #line 3467 "tracker-sparql-pattern.c" 3472 } else { 3473 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3474 __g_list_free__g_object_unref0_0 (where_bindings); 3475 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3476 _tracker_sparql_context_unref0 (pattern); 3477 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3478 __g_list_free__g_object_unref0_0 (old_bindings); 3479 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3480 _g_string_free0 (pattern_sql); 3481 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3482 _tracker_sparql_context_unref0 (_result_); 3483 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3484 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3485 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3486 g_clear_error (&_inner_error_); 3487 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3488 return NULL; 3489 #line 3485 "tracker-sparql-pattern.c" 3490 } 3491 } 3492 #line 389 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3493 if (_tmp164_) { 3494 #line 3490 "tracker-sparql-pattern.c" 3495 GString* _tmp165_; 3496 gboolean first_order; 3497 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3498 tracker_sparql_pattern_expect (self, TRACKER_SPARQL_TOKEN_TYPE_BY, &_inner_error_); 3499 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3500 if (_inner_error_ != NULL) { 3501 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3502 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3503 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3504 g_propagate_error (error, _inner_error_); 3505 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3506 __g_list_free__g_object_unref0_0 (where_bindings); 3507 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3508 _tracker_sparql_context_unref0 (pattern); 3509 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3510 __g_list_free__g_object_unref0_0 (old_bindings); 3511 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3512 _g_string_free0 (pattern_sql); 3513 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3514 _tracker_sparql_context_unref0 (_result_); 3515 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3516 return NULL; 3517 #line 3513 "tracker-sparql-pattern.c" 3518 } else { 3519 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3520 __g_list_free__g_object_unref0_0 (where_bindings); 3521 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3522 _tracker_sparql_context_unref0 (pattern); 3523 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3524 __g_list_free__g_object_unref0_0 (old_bindings); 3525 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3526 _g_string_free0 (pattern_sql); 3527 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3528 _tracker_sparql_context_unref0 (_result_); 3529 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3530 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3531 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3532 g_clear_error (&_inner_error_); 3533 #line 390 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3534 return NULL; 3535 #line 3531 "tracker-sparql-pattern.c" 3536 } 3537 } 3538 #line 391 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3539 _tmp165_ = sql; 3540 #line 391 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3541 g_string_append (_tmp165_, " ORDER BY "); 3542 #line 392 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3543 first_order = TRUE; 3544 #line 3540 "tracker-sparql-pattern.c" 3545 { 3546 gboolean _tmp166_; 3547 #line 393 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3548 _tmp166_ = TRUE; 3549 #line 393 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3550 while (TRUE) { 3551 #line 3547 "tracker-sparql-pattern.c" 3552 gboolean _tmp167_; 3553 gboolean _tmp181_; 3554 TrackerSparqlExpression* _tmp183_; 3555 GString* _tmp184_; 3556 #line 393 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3557 _tmp167_ = _tmp166_; 3558 #line 393 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3559 if (!_tmp167_) { 3560 #line 3556 "tracker-sparql-pattern.c" 3561 gboolean _tmp168_ = FALSE; 3562 gboolean _tmp169_ = FALSE; 3563 gboolean _tmp170_ = FALSE; 3564 gboolean _tmp171_ = FALSE; 3565 TrackerSparqlTokenType _tmp172_ = 0; 3566 gboolean _tmp174_; 3567 gboolean _tmp176_; 3568 gboolean _tmp178_; 3569 gboolean _tmp180_; 3570 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3571 _tmp172_ = tracker_sparql_pattern_current (self); 3572 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3573 if (_tmp172_ != TRACKER_SPARQL_TOKEN_TYPE_LIMIT) { 3574 #line 3570 "tracker-sparql-pattern.c" 3575 TrackerSparqlTokenType _tmp173_ = 0; 3576 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3577 _tmp173_ = tracker_sparql_pattern_current (self); 3578 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3579 _tmp171_ = _tmp173_ != TRACKER_SPARQL_TOKEN_TYPE_OFFSET; 3580 #line 3576 "tracker-sparql-pattern.c" 3581 } else { 3582 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3583 _tmp171_ = FALSE; 3584 #line 3580 "tracker-sparql-pattern.c" 3585 } 3586 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3587 _tmp174_ = _tmp171_; 3588 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3589 if (_tmp174_) { 3590 #line 3586 "tracker-sparql-pattern.c" 3591 TrackerSparqlTokenType _tmp175_ = 0; 3592 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3593 _tmp175_ = tracker_sparql_pattern_current (self); 3594 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3595 _tmp170_ = _tmp175_ != TRACKER_SPARQL_TOKEN_TYPE_CLOSE_BRACE; 3596 #line 3592 "tracker-sparql-pattern.c" 3597 } else { 3598 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3599 _tmp170_ = FALSE; 3600 #line 3596 "tracker-sparql-pattern.c" 3601 } 3602 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3603 _tmp176_ = _tmp170_; 3604 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3605 if (_tmp176_) { 3606 #line 3602 "tracker-sparql-pattern.c" 3607 TrackerSparqlTokenType _tmp177_ = 0; 3608 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3609 _tmp177_ = tracker_sparql_pattern_current (self); 3610 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3611 _tmp169_ = _tmp177_ != TRACKER_SPARQL_TOKEN_TYPE_CLOSE_PARENS; 3612 #line 3608 "tracker-sparql-pattern.c" 3613 } else { 3614 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3615 _tmp169_ = FALSE; 3616 #line 3612 "tracker-sparql-pattern.c" 3617 } 3618 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3619 _tmp178_ = _tmp169_; 3620 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3621 if (_tmp178_) { 3622 #line 3618 "tracker-sparql-pattern.c" 3623 TrackerSparqlTokenType _tmp179_ = 0; 3624 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3625 _tmp179_ = tracker_sparql_pattern_current (self); 3626 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3627 _tmp168_ = _tmp179_ != TRACKER_SPARQL_TOKEN_TYPE_EOF; 3628 #line 3624 "tracker-sparql-pattern.c" 3629 } else { 3630 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3631 _tmp168_ = FALSE; 3632 #line 3628 "tracker-sparql-pattern.c" 3633 } 3634 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3635 _tmp180_ = _tmp168_; 3636 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3637 if (!_tmp180_) { 3638 #line 400 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3639 break; 3640 #line 3636 "tracker-sparql-pattern.c" 3641 } 3642 } 3643 #line 393 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3644 _tmp166_ = FALSE; 3645 #line 394 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3646 _tmp181_ = first_order; 3647 #line 394 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3648 if (_tmp181_) { 3649 #line 395 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3650 first_order = FALSE; 3651 #line 3647 "tracker-sparql-pattern.c" 3652 } else { 3653 GString* _tmp182_; 3654 #line 397 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3655 _tmp182_ = sql; 3656 #line 397 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3657 g_string_append (_tmp182_, ", "); 3658 #line 3654 "tracker-sparql-pattern.c" 3659 } 3660 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3661 _tmp183_ = self->priv->expression; 3662 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3663 _tmp184_ = sql; 3664 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3665 tracker_sparql_expression_translate_order_condition (_tmp183_, _tmp184_, &_inner_error_); 3666 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3667 if (_inner_error_ != NULL) { 3668 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3669 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3670 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3671 g_propagate_error (error, _inner_error_); 3672 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3673 __g_list_free__g_object_unref0_0 (where_bindings); 3674 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3675 _tracker_sparql_context_unref0 (pattern); 3676 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3677 __g_list_free__g_object_unref0_0 (old_bindings); 3678 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3679 _g_string_free0 (pattern_sql); 3680 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3681 _tracker_sparql_context_unref0 (_result_); 3682 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3683 return NULL; 3684 #line 3680 "tracker-sparql-pattern.c" 3685 } else { 3686 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3687 __g_list_free__g_object_unref0_0 (where_bindings); 3688 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3689 _tracker_sparql_context_unref0 (pattern); 3690 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3691 __g_list_free__g_object_unref0_0 (old_bindings); 3692 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3693 _g_string_free0 (pattern_sql); 3694 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3695 _tracker_sparql_context_unref0 (_result_); 3696 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3697 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3698 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3699 g_clear_error (&_inner_error_); 3700 #line 399 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3701 return NULL; 3702 #line 3698 "tracker-sparql-pattern.c" 3703 } 3704 } 3705 } 3706 } 3707 } 3708 #line 403 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3709 limit = -1; 3710 #line 404 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3711 offset = -1; 3712 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3713 _tmp185_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_LIMIT, &_inner_error_); 3714 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3715 _tmp186_ = _tmp185_; 3716 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3717 if (_inner_error_ != NULL) { 3718 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3719 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3720 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3721 g_propagate_error (error, _inner_error_); 3722 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3723 __g_list_free__g_object_unref0_0 (where_bindings); 3724 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3725 _tracker_sparql_context_unref0 (pattern); 3726 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3727 __g_list_free__g_object_unref0_0 (old_bindings); 3728 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3729 _g_string_free0 (pattern_sql); 3730 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3731 _tracker_sparql_context_unref0 (_result_); 3732 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3733 return NULL; 3734 #line 3730 "tracker-sparql-pattern.c" 3735 } else { 3736 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3737 __g_list_free__g_object_unref0_0 (where_bindings); 3738 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3739 _tracker_sparql_context_unref0 (pattern); 3740 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3741 __g_list_free__g_object_unref0_0 (old_bindings); 3742 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3743 _g_string_free0 (pattern_sql); 3744 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3745 _tracker_sparql_context_unref0 (_result_); 3746 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3747 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3748 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3749 g_clear_error (&_inner_error_); 3750 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3751 return NULL; 3752 #line 3748 "tracker-sparql-pattern.c" 3753 } 3754 } 3755 #line 406 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3756 if (_tmp186_) { 3757 #line 3753 "tracker-sparql-pattern.c" 3758 gchar* _tmp187_ = NULL; 3759 gchar* _tmp188_; 3760 gint _tmp189_ = 0; 3761 gboolean _tmp190_ = FALSE; 3762 gboolean _tmp191_; 3763 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3764 tracker_sparql_pattern_expect (self, TRACKER_SPARQL_TOKEN_TYPE_INTEGER, &_inner_error_); 3765 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3766 if (_inner_error_ != NULL) { 3767 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3768 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3769 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3770 g_propagate_error (error, _inner_error_); 3771 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3772 __g_list_free__g_object_unref0_0 (where_bindings); 3773 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3774 _tracker_sparql_context_unref0 (pattern); 3775 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3776 __g_list_free__g_object_unref0_0 (old_bindings); 3777 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3778 _g_string_free0 (pattern_sql); 3779 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3780 _tracker_sparql_context_unref0 (_result_); 3781 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3782 return NULL; 3783 #line 3779 "tracker-sparql-pattern.c" 3784 } else { 3785 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3786 __g_list_free__g_object_unref0_0 (where_bindings); 3787 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3788 _tracker_sparql_context_unref0 (pattern); 3789 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3790 __g_list_free__g_object_unref0_0 (old_bindings); 3791 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3792 _g_string_free0 (pattern_sql); 3793 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3794 _tracker_sparql_context_unref0 (_result_); 3795 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3796 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3797 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3798 g_clear_error (&_inner_error_); 3799 #line 407 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3800 return NULL; 3801 #line 3797 "tracker-sparql-pattern.c" 3802 } 3803 } 3804 #line 408 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3805 _tmp187_ = tracker_sparql_pattern_get_last_string (self, 0); 3806 #line 408 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3807 _tmp188_ = _tmp187_; 3808 #line 408 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3809 _tmp189_ = atoi (_tmp188_); 3810 #line 408 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3811 limit = _tmp189_; 3812 #line 408 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3813 _g_free0 (_tmp188_); 3814 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3815 _tmp190_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_OFFSET, &_inner_error_); 3816 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3817 _tmp191_ = _tmp190_; 3818 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3819 if (_inner_error_ != NULL) { 3820 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3821 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3822 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3823 g_propagate_error (error, _inner_error_); 3824 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3825 __g_list_free__g_object_unref0_0 (where_bindings); 3826 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3827 _tracker_sparql_context_unref0 (pattern); 3828 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3829 __g_list_free__g_object_unref0_0 (old_bindings); 3830 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3831 _g_string_free0 (pattern_sql); 3832 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3833 _tracker_sparql_context_unref0 (_result_); 3834 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3835 return NULL; 3836 #line 3832 "tracker-sparql-pattern.c" 3837 } else { 3838 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3839 __g_list_free__g_object_unref0_0 (where_bindings); 3840 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3841 _tracker_sparql_context_unref0 (pattern); 3842 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3843 __g_list_free__g_object_unref0_0 (old_bindings); 3844 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3845 _g_string_free0 (pattern_sql); 3846 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3847 _tracker_sparql_context_unref0 (_result_); 3848 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3849 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3850 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3851 g_clear_error (&_inner_error_); 3852 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3853 return NULL; 3854 #line 3850 "tracker-sparql-pattern.c" 3855 } 3856 } 3857 #line 409 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3858 if (_tmp191_) { 3859 #line 3855 "tracker-sparql-pattern.c" 3860 gchar* _tmp192_ = NULL; 3861 gchar* _tmp193_; 3862 gint _tmp194_ = 0; 3863 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3864 tracker_sparql_pattern_expect (self, TRACKER_SPARQL_TOKEN_TYPE_INTEGER, &_inner_error_); 3865 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3866 if (_inner_error_ != NULL) { 3867 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3868 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3869 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3870 g_propagate_error (error, _inner_error_); 3871 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3872 __g_list_free__g_object_unref0_0 (where_bindings); 3873 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3874 _tracker_sparql_context_unref0 (pattern); 3875 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3876 __g_list_free__g_object_unref0_0 (old_bindings); 3877 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3878 _g_string_free0 (pattern_sql); 3879 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3880 _tracker_sparql_context_unref0 (_result_); 3881 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3882 return NULL; 3883 #line 3879 "tracker-sparql-pattern.c" 3884 } else { 3885 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3886 __g_list_free__g_object_unref0_0 (where_bindings); 3887 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3888 _tracker_sparql_context_unref0 (pattern); 3889 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3890 __g_list_free__g_object_unref0_0 (old_bindings); 3891 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3892 _g_string_free0 (pattern_sql); 3893 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3894 _tracker_sparql_context_unref0 (_result_); 3895 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3896 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3897 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3898 g_clear_error (&_inner_error_); 3899 #line 410 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3900 return NULL; 3901 #line 3897 "tracker-sparql-pattern.c" 3902 } 3903 } 3904 #line 411 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3905 _tmp192_ = tracker_sparql_pattern_get_last_string (self, 0); 3906 #line 411 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3907 _tmp193_ = _tmp192_; 3908 #line 411 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3909 _tmp194_ = atoi (_tmp193_); 3910 #line 411 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3911 offset = _tmp194_; 3912 #line 411 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3913 _g_free0 (_tmp193_); 3914 #line 3910 "tracker-sparql-pattern.c" 3915 } 3916 } else { 3917 gboolean _tmp195_ = FALSE; 3918 gboolean _tmp196_; 3919 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3920 _tmp195_ = tracker_sparql_pattern_accept (self, TRACKER_SPARQL_TOKEN_TYPE_OFFSET, &_inner_error_); 3921 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3922 _tmp196_ = _tmp195_; 3923 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3924 if (_inner_error_ != NULL) { 3925 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3926 if (_inner_error_->domain == TRACKER_SPARQL_ERROR) { 3927 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3928 g_propagate_error (error, _inner_error_); 3929 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3930 __g_list_free__g_object_unref0_0 (where_bindings); 3931 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3932 _tracker_sparql_context_unref0 (pattern); 3933 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3934 __g_list_free__g_object_unref0_0 (old_bindings); 3935 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3936 _g_string_free0 (pattern_sql); 3937 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3938 _tracker_sparql_context_unref0 (_result_); 3939 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3940 return NULL; 3941 #line 3937 "tracker-sparql-pattern.c" 3942 } else { 3943 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3944 __g_list_free__g_object_unref0_0 (where_bindings); 3945 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3946 _tracker_sparql_context_unref0 (pattern); 3947 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3948 __g_list_free__g_object_unref0_0 (old_bindings); 3949 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3950 _g_string_free0 (pattern_sql); 3951 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3952 _tracker_sparql_context_unref0 (_result_); 3953 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3954 g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code); 3955 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3956 g_clear_error (&_inner_error_); 3957 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3958 return NULL; 3959 #line 3955 "tracker-sparql-pattern.c" 3960 } 3961 } 3962 #line 413 "/home/martyn/Source/tracker/src/libtracker-data/tracker-sparql-pattern.vala" 3963 if (_tmp196_) { 3964 #line 3960 "tracker-sparql-pattern.c" 3965 gchar* _tmp197_ = NULL; 3966 gchar* _tmp198_; 3967 gint _tmp199_