aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp/tree.c
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2004-01-30 15:37:39 -0800
committerRichard Henderson <rth@gcc.gnu.org>2004-01-30 15:37:39 -0800
commit59445d742771835d8a0a8f59e10ae1b19f79fff8 (patch)
tree1d81f008b1896f9ddadfabf50c34307f267b2676 /gcc/cp/tree.c
parent7c960b3dffaa649a5d7d1a1fc71ed14804dfc445 (diff)
downloadgcc-59445d742771835d8a0a8f59e10ae1b19f79fff8.zip
gcc-59445d742771835d8a0a8f59e10ae1b19f79fff8.tar.gz
gcc-59445d742771835d8a0a8f59e10ae1b19f79fff8.tar.bz2
re PR c++/13693 ([tree-ssa] build failure in mipsisa64-elf)
PR c++/13693 * method.c (use_thunk): Don't force_target_expr for void thunks. * tree.c (build_target_expr_with_type): Assert non-void type. (force_target_expr): Likewise. From-SVN: r77008
Diffstat (limited to 'gcc/cp/tree.c')
-rw-r--r--gcc/cp/tree.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c
index bedbbe9..7d98128 100644
--- a/gcc/cp/tree.c
+++ b/gcc/cp/tree.c
@@ -318,6 +318,8 @@ build_target_expr_with_type (tree init, tree type)
{
tree slot;
+ my_friendly_assert (!VOID_TYPE_P (type), 20040130);
+
if (TREE_CODE (init) == TARGET_EXPR)
return init;
else if (CLASS_TYPE_P (type) && !TYPE_HAS_TRIVIAL_INIT_REF (type)
@@ -342,7 +344,11 @@ build_target_expr_with_type (tree init, tree type)
tree
force_target_expr (tree type, tree init)
{
- tree slot = build_local_temp (type);
+ tree slot;
+
+ my_friendly_assert (!VOID_TYPE_P (type), 20040130);
+
+ slot = build_local_temp (type);
return build_target_expr (slot, init);
}