summaryrefslogtreecommitdiff
path: root/gcc/tree-flow-inline.h
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/tree-flow-inline.h')
-rw-r--r--gcc/tree-flow-inline.h10
1 files changed, 10 insertions, 0 deletions
diff --git a/gcc/tree-flow-inline.h b/gcc/tree-flow-inline.h
index 7e935378c81..7103d238b09 100644
--- a/gcc/tree-flow-inline.h
+++ b/gcc/tree-flow-inline.h
@@ -98,6 +98,16 @@ next_htab_element (htab_iterator *hti)
return NULL;
}
+/* Get the variable with uid UID from the list of referenced vars. */
+
+static inline tree
+referenced_var (unsigned int uid)
+{
+ tree var = referenced_var_lookup (uid);
+ gcc_assert (var || uid == 0);
+ return var;
+}
+
/* Initialize ITER to point to the first referenced variable in the
referenced_vars hashtable, and return that variable. */