Use decl_type in create_variable_info_for_1
authorTom de Vries <tom@codesourcery.com>
Wed, 4 Nov 2015 14:18:34 +0000 (14:18 +0000)
committerTom de Vries <vries@gcc.gnu.org>
Wed, 4 Nov 2015 14:18:34 +0000 (14:18 +0000)
2015-11-04  Tom de Vries  <tom@codesourcery.com>

* tree-ssa-structalias.c (create_variable_info_for_1): Use decl_type
variable.

From-SVN: r229754

gcc/ChangeLog
gcc/tree-ssa-structalias.c

index 0375249ee99e68bda5cbc6bd5c42be6e02743fda..9b82fc2ac96f846c3fd82117cb8e10aa87153414 100644 (file)
@@ -1,3 +1,8 @@
+2015-11-04  Tom de Vries  <tom@codesourcery.com>
+
+       * tree-ssa-structalias.c (create_variable_info_for_1): Use decl_type
+       variable.
+
 2015-11-03  Trevor Saunders  <tbsaunde+gcc@tbsaunde.org>
 
        * config/arm/coff.h: Remove.
index ded5a1e2ac765981edf91b10fef9a26bbf498305..98b5f168032e3a2b7332ed7906f84dcc2053a9dc 100644 (file)
@@ -5718,8 +5718,8 @@ create_variable_info_for_1 (tree decl, const char *name, bool add_id)
       vi->fullsize = tree_to_uhwi (declsize);
       vi->size = vi->fullsize;
       vi->is_full_var = true;
-      if (POINTER_TYPE_P (TREE_TYPE (decl))
-         && TYPE_RESTRICT (TREE_TYPE (decl)))
+      if (POINTER_TYPE_P (decl_type)
+         && TYPE_RESTRICT (decl_type))
        vi->only_restrict_pointers = 1;
       fieldstack.release ();
       return vi;