Bug 33465 - Broken diagnostic: 'fix_trunc_expr' and 'float_expr' not supported by dump_expr
Summary: Broken diagnostic: 'fix_trunc_expr' and 'float_expr' not supported by dump_expr
Status: RESOLVED FIXED
Alias: None
Product: gcc
Classification: Unclassified
Component: c++ (show other bugs)
Version: 4.3.0
: P3 normal
Target Milestone: 4.4.0
Assignee: Paolo Carlini
URL:
Keywords: diagnostic, monitored
Depends on:
Blocks:
 
Reported: 2007-09-17 22:29 UTC by Volker Reichelt
Modified: 2009-01-30 15:05 UTC (History)
2 users (show)

See Also:
Host:
Target:
Build:
Known to work:
Known to fail:
Last reconfirmed: 2009-01-30 03:22:54


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Volker Reichelt 2007-09-17 22:29:39 UTC
The following invalid testcase triggers a broken diagnostic since at least
GCC 2.95.3:

===================================
int foo(int);

void bar(double d)
{
  foo(d)();
}
===================================

bug.cc: In function 'void bar(double)':
bug.cc:5: error: 'foo(#'fix_trunc_expr' not supported by dump_expr#<expression error>)' cannot be used as a function


The other conversion is broken, too:

===================================
int foo(double);

void bar(int i)
{
  foo(i)();
}
===================================

bug.cc: In function 'void bar(int)':
bug.cc:5: error: 'foo(#'float_expr' not supported by dump_expr#<expression error>)' cannot be used as a function
Comment 1 Paolo Carlini 2009-01-30 03:22:54 UTC
On it.
Comment 2 paolo@gcc.gnu.org 2009-01-30 15:03:24 UTC
Subject: Bug 33465

Author: paolo
Date: Fri Jan 30 15:03:10 2009
New Revision: 143790

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=143790
Log:
/cp
2009-01-30  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/33465
	* error.c (dump_expr): Handle FIX_TRUNC_EXPR and FLOAT_EXPR.

/testsuite
2009-01-30  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/33465
	* g++.dg/parse/error34.C: New.
	* g++.dg/parse/error35.C: Likewise.

/cp
2009-01-30  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/38655
	* error.c (dump_type_prefix, dump_type_suffix): Handle FIXED_POINT_TYPE.

/testsuite
2009-01-30  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/38655
	* g++.dg/cpp0x/decltype-38655.C: New.

Added:
    trunk/gcc/testsuite/g++.dg/cpp0x/decltype-38655.C   (with props)
    trunk/gcc/testsuite/g++.dg/parse/error34.C
    trunk/gcc/testsuite/g++.dg/parse/error35.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/error.c
    trunk/gcc/testsuite/ChangeLog

Propchange: trunk/gcc/testsuite/g++.dg/cpp0x/decltype-38655.C
            ('svn:mergeinfo' added)


Comment 3 Paolo Carlini 2009-01-30 15:05:24 UTC
Fixed for 4.4.0.