aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog5
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/g++.dg/lto/20101009-1_0.C14
-rw-r--r--gcc/tree.c2
4 files changed, 25 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index ea7fced..5c4d210 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,8 @@
+2010-10-09 Richard Guenther <rguenther@suse.de>
+
+ PR lto/45947
+ * tree.c (free_lang_data_in_cgraph): Properly walk the varpool.
+
2010-10-09 Nathan Froyd <froydnj@codesourcery.com>
* config/mmix/mmix-protos.h (mmix_function_arg): Delete.
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 3641bf6..9c16eed 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,5 +1,10 @@
2010-10-09 Richard Guenther <rguenther@suse.de>
+ PR lto/45947
+ * g++.dg/lto/20101009-1_0.C: New testcase.
+
+2010-10-09 Richard Guenther <rguenther@suse.de>
+
PR tree-optimization/45945
* gcc.dg/lto/20101009-1_0.c: New testcase.
diff --git a/gcc/testsuite/g++.dg/lto/20101009-1_0.C b/gcc/testsuite/g++.dg/lto/20101009-1_0.C
new file mode 100644
index 0000000..b7cc5bc
--- /dev/null
+++ b/gcc/testsuite/g++.dg/lto/20101009-1_0.C
@@ -0,0 +1,14 @@
+// { dg-lto-do link }
+
+template < typename > struct X
+{
+ template < typename > static int test ();
+ static const int i = sizeof (test < int >());
+};
+
+template struct X < int >;
+
+int main()
+{
+ return 0;
+}
diff --git a/gcc/tree.c b/gcc/tree.c
index d068a7e..cf5881a 100644
--- a/gcc/tree.c
+++ b/gcc/tree.c
@@ -4982,7 +4982,7 @@ free_lang_data_in_cgraph (void)
find_decls_types (p->decl, &fld);
/* Find decls and types in every varpool symbol. */
- for (v = varpool_nodes_queue; v; v = v->next_needed)
+ for (v = varpool_nodes; v; v = v->next)
find_decls_types_in_var (v, &fld);
/* Set the assembler name on every decl found. We need to do this