cvt.c (perform_qualification_conversions): Use comp_target_types instead of comp_ptr_ttypes.

* cvt.c (perform_qualification_conversions): Use comp_target_types
	instead of comp_ptr_ttypes.

From-SVN: r18838
This commit is contained in:
Mark Mitchell 1998-03-26 10:23:14 +00:00 committed by Mark Mitchell
parent 04d02ece5e
commit 17b75c9182
3 changed files with 26 additions and 1 deletions

View File

@ -1,3 +1,8 @@
Thu Mar 26 10:23:24 1998 Mark Mitchell <mmitchell@usa.net>
* cvt.c (perform_qualification_conversions): Use comp_target_types
instead of comp_ptr_ttypes.
Wed Mar 25 16:10:50 1998 Mark Mitchell <mmitchell@usa.net>
* cp-tree.h (enforce_access): Declare.

View File

@ -1078,7 +1078,7 @@ perform_qualification_conversions (type, expr)
tree type;
tree expr;
{
if (comp_ptr_ttypes (type, TREE_TYPE(expr)))
if (comp_target_types (type, TREE_TYPE (expr), 0) == 1)
return build1 (NOP_EXPR, type, expr);
else
return error_mark_node;

View File

@ -0,0 +1,20 @@
// Build don't link:
enum E { };
template <const E* ep>
struct S1
{
};
struct S2
{
static E es[1];
};
struct S3
{
typedef S1<S2::es> S3_Type;
};