I noticed that the previous patch still had issues about more then one
attribute added. The underlying issue seems here that we shouldn't
chain attributes simply, but we should merge them.
I did full bootstrap for it and ran regression tests for
x86_64-unknown-linux-gnu. Ok for apply?
Regards,
Kai
Revised patch:
Index: gcc/cp/decl2.c
===================================================================
--- gcc/cp/decl2.c (revision 183106)
+++ gcc/cp/decl2.c (working copy)
@@ -1200,9 +1200,9 @@
old_attrs = *q;
- /* Place the late attributes at the beginning of the attribute
+ /* Merge the late attributes at the beginning with the attribute
list. */
- TREE_CHAIN (tree_last (late_attrs)) = *q;
+ late_attrs = merge_attributes (late_attrs, *q);
*q = late_attrs;
if (!DECL_P (*decl_p) && *decl_p == TYPE_MAIN_VARIANT (*decl_p))