aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/tree.cc
diff options
context:
space:
mode:
authorJason Merrill <jason@redhat.com>2022-12-12 17:41:39 -0500
committerJason Merrill <jason@redhat.com>2022-12-12 17:46:31 -0500
commit77ebee2bd04cc727161875869b135675d035c66e (patch)
tree7abd8ff1494cc73bad0fc71d7622f8804ac2eda1 /gcc/cp/tree.cc
parent11c72cd3c8b06f057ce16c95966331ded692fd4e (diff)
downloadgcc-77ebee2bd04cc727161875869b135675d035c66e.zip
gcc-77ebee2bd04cc727161875869b135675d035c66e.tar.gz
gcc-77ebee2bd04cc727161875869b135675d035c66e.tar.bz2
Revert "c++: build initializer_list<string> in a loop [PR105838]"
This patch broke a couple of different patterns; reverting while I work on a fix. PR c++/108701 This reverts commit bd0485f20f4794f9787237706a6308473a8e9415.
Diffstat (limited to 'gcc/cp/tree.cc')
-rw-r--r--gcc/cp/tree.cc2
1 files changed, 2 insertions, 0 deletions
diff --git a/gcc/cp/tree.cc b/gcc/cp/tree.cc
index a600178..33bde16 100644
--- a/gcc/cp/tree.cc
+++ b/gcc/cp/tree.cc
@@ -785,6 +785,8 @@ build_vec_init_elt (tree type, tree init, tsubst_flags_t complain)
releasing_vec argvec;
if (init && !BRACE_ENCLOSED_INITIALIZER_P (init))
{
+ gcc_assert (same_type_ignoring_top_level_qualifiers_p
+ (type, TREE_TYPE (init)));
tree init_type = strip_array_types (TREE_TYPE (init));
tree dummy = build_dummy_object (init_type);
if (!lvalue_p (init))