diff options
author | Paolo Carlini <paolo@gcc.gnu.org> | 2007-05-31 08:58:47 +0000 |
---|---|---|
committer | Paolo Carlini <paolo@gcc.gnu.org> | 2007-05-31 08:58:47 +0000 |
commit | 10c1d4af2f3020e5ed8ff7356f06802668e78324 (patch) | |
tree | 2f93032e385e7877b9039accd370b84fd24d6dfc /gcc/cp/semantics.c | |
parent | fdecbf80705f71143b2ef3e598067b582be95903 (diff) | |
download | gcc-10c1d4af2f3020e5ed8ff7356f06802668e78324.zip gcc-10c1d4af2f3020e5ed8ff7356f06802668e78324.tar.gz gcc-10c1d4af2f3020e5ed8ff7356f06802668e78324.tar.bz2 |
re PR c++/32158 (uninitialized_fill compile failure if no default assignment operator)
gcc/cp
2007-05-31 Paolo Carlini <pcarlini@suse.de>
PR c++/32158
* semantics.c (finish_trait_expr): Complete the types.
gcc/testsuite
2007-05-31 Paolo Carlini <pcarlini@suse.de>
PR c++/32158
* g++.dg/ext/is_pod_incomplete.C: New.
From-SVN: r125217
Diffstat (limited to 'gcc/cp/semantics.c')
-rw-r--r-- | gcc/cp/semantics.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c index 631f5e8..4a9ea8c 100644 --- a/gcc/cp/semantics.c +++ b/gcc/cp/semantics.c @@ -4177,11 +4177,15 @@ finish_trait_expr (cp_trait_kind kind, tree type1, tree type2) return trait_expr; } + complete_type (type1); + if (type2) + complete_type (type2); + /* The only required diagnostic. */ if (kind == CPTK_IS_BASE_OF && NON_UNION_CLASS_TYPE_P (type1) && NON_UNION_CLASS_TYPE_P (type2) && !same_type_ignoring_top_level_qualifiers_p (type1, type2) - && !COMPLETE_TYPE_P (complete_type (type2))) + && !COMPLETE_TYPE_P (type2)) { error ("incomplete type %qT not allowed", type2); return error_mark_node; |