aboutsummaryrefslogtreecommitdiff
path: root/gcc/cp
diff options
context:
space:
mode:
authorGabriel Dos Reis <gdr@integrable-solutions.net>2002-12-13 21:58:54 +0000
committerGabriel Dos Reis <gdr@gcc.gnu.org>2002-12-13 21:58:54 +0000
commit75c525d71b62065102c3760de9e8015c141cfa3d (patch)
tree2199ef403788353883d10b25b9bae81faa2269b7 /gcc/cp
parent8c6ae51fa9f2395b9d3e3f6d8734c8c099755922 (diff)
downloadgcc-75c525d71b62065102c3760de9e8015c141cfa3d.zip
gcc-75c525d71b62065102c3760de9e8015c141cfa3d.tar.gz
gcc-75c525d71b62065102c3760de9e8015c141cfa3d.tar.bz2
re PR c++/8031 (ICE in comptypes, at cp/typeck.c:913)
PR C++/8031 * cvt.c (convert_to_pointer_force): Don't try comparing against erronous type. From-SVN: r60106
Diffstat (limited to 'gcc/cp')
-rw-r--r--gcc/cp/ChangeLog6
-rw-r--r--gcc/cp/cvt.c2
2 files changed, 8 insertions, 0 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index c2627ba..096b906 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,9 @@
+2002-12-13 Gabriel Dos Reis <gdr@integrable-solutions.net>
+
+ PR C++/8031
+ * cvt.c (convert_to_pointer_force): Don't try comparing against
+ erronous type.
+
2002-12-13 Geoffrey Keating <geoffk@apple.com>
* cp-tree.h: Have the multiple-include guards around
diff --git a/gcc/cp/cvt.c b/gcc/cp/cvt.c
index 7e31045..97d2420 100644
--- a/gcc/cp/cvt.c
+++ b/gcc/cp/cvt.c
@@ -322,6 +322,8 @@ convert_to_pointer_force (type, expr)
if (binfo)
{
expr = build_base_path (code, expr, binfo, 0);
+ if (expr == error_mark_node)
+ return error_mark_node;
/* Add any qualifier conversions. */
if (!same_type_p (TREE_TYPE (TREE_TYPE (expr)),
TREE_TYPE (type)))