public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/35338]  New: [4.3/4.4 regression] Broken diagnostics for fixed-point types
@ 2008-02-23 19:56 reichelt at gcc dot gnu dot org
  2008-02-23 19:56 ` [Bug c++/35338] " reichelt at gcc dot gnu dot org
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2008-02-23 19:56 UTC (permalink / raw)
  To: gcc-bugs

Broken diagnostics are issued for the following invalid code snippet
on mainline and 4.3 branch:

====================================================
int i = 1r;
bool b = !1r;
====================================================

bug.cc:1: error: cannot convert '#'fixed_point_type' not supported by
dump_type#<type error>' to 'int' in initialization
bug.cc:2: error: could not convert '#'fixed_cst' not supported by
dump_expr#<expression error>' to 'bool'
bug.cc:2: error: in argument to unary !


-- 
           Summary: [4.3/4.4 regression] Broken diagnostics for fixed-point
                    types
           Product: gcc
           Version: 4.4.0
            Status: UNCONFIRMED
          Keywords: diagnostic, monitored
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: reichelt at gcc dot gnu dot org


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] [4.3/4.4 regression] Broken diagnostics for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
@ 2008-02-23 19:56 ` reichelt at gcc dot gnu dot org
  2008-02-24 22:00 ` rguenth at gcc dot gnu dot org
                   ` (8 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2008-02-23 19:56 UTC (permalink / raw)
  To: gcc-bugs



-- 

reichelt at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |4.3.0


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] [4.3/4.4 regression] Broken diagnostics for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
  2008-02-23 19:56 ` [Bug c++/35338] " reichelt at gcc dot gnu dot org
@ 2008-02-24 22:00 ` rguenth at gcc dot gnu dot org
  2008-02-25 17:04 ` pcarlini at suse dot de
                   ` (7 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2008-02-24 22:00 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from rguenth at gcc dot gnu dot org  2008-02-24 21:59 -------
Confirmed.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
     Ever Confirmed|0                           |1
           Priority|P3                          |P2
   Last reconfirmed|0000-00-00 00:00:00         |2008-02-24 21:59:44
               date|                            |


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] [4.3/4.4 regression] Broken diagnostics for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
  2008-02-23 19:56 ` [Bug c++/35338] " reichelt at gcc dot gnu dot org
  2008-02-24 22:00 ` rguenth at gcc dot gnu dot org
@ 2008-02-25 17:04 ` pcarlini at suse dot de
  2008-02-25 19:06 ` paolo at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: pcarlini at suse dot de @ 2008-02-25 17:04 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from pcarlini at suse dot de  2008-02-25 17:03 -------
Seems simple.


-- 

pcarlini at suse dot de changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |pcarlini at suse dot de
                   |dot org                     |
             Status|NEW                         |ASSIGNED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] [4.3/4.4 regression] Broken diagnostics for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2008-02-25 17:04 ` pcarlini at suse dot de
@ 2008-02-25 19:06 ` paolo at gcc dot gnu dot org
  2008-03-06 17:52 ` [Bug c++/35338] [4.3 " paolo at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: paolo at gcc dot gnu dot org @ 2008-02-25 19:06 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from paolo at gcc dot gnu dot org  2008-02-25 19:05 -------
Subject: Bug 35338

Author: paolo
Date: Mon Feb 25 19:04:50 2008
New Revision: 132634

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=132634
Log:
/cp
2008-02-25  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35333
        * error.c (dump_expr): Handle CONJ_EXPR.

/testsuite
2008-02-25  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35333
        * g++.dg/other/error26.C: New.

/cp
2008-02-25  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35338
        * error.c (dump_type): Handle FIXED_POINT_TYPE.
        (dump_expr): Handle FIXED_CST.

/testsuite
2008-02-25  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35338
        * g++.dg/other/error25.C: New.

Added:
    trunk/gcc/testsuite/g++.dg/other/error25.C
    trunk/gcc/testsuite/g++.dg/other/error26.C
Modified:
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/error.c
    trunk/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] [4.3 regression] Broken diagnostics for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2008-02-25 19:06 ` paolo at gcc dot gnu dot org
@ 2008-03-06 17:52 ` paolo at gcc dot gnu dot org
  2008-03-06 17:53 ` pcarlini at suse dot de
                   ` (4 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: paolo at gcc dot gnu dot org @ 2008-03-06 17:52 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from paolo at gcc dot gnu dot org  2008-03-06 17:51 -------
Subject: Bug 35338

Author: paolo
Date: Thu Mar  6 17:50:54 2008
New Revision: 132980

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=132980
Log:
/cp
2008-03-06  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35323
        * name-lookup.c (arg_assoc_type): Handle FIXED_POINT_TYPE.

/testsuite
2008-03-06  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35323
        * g++.dg/lookup/crash7.C: New.

/cp
2008-03-06  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35333
        * error.c (dump_expr): Handle CONJ_EXPR.

/testsuite
2008-03-06  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35333
        * g++.dg/other/error26.C: New.

/cp
2008-03-06  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35338
        * error.c (dump_type): Handle FIXED_POINT_TYPE.
        (dump_expr): Handle FIXED_CST.

/testsuite
2008-03-06  Paolo Carlini  <pcarlini@suse.de>

        PR c++/35338
        * g++.dg/other/error25.C: New.

Added:
    branches/gcc-4_3-branch/gcc/testsuite/g++.dg/lookup/crash7.C
    branches/gcc-4_3-branch/gcc/testsuite/g++.dg/other/error25.C
    branches/gcc-4_3-branch/gcc/testsuite/g++.dg/other/error26.C
Modified:
    branches/gcc-4_3-branch/gcc/cp/ChangeLog
    branches/gcc-4_3-branch/gcc/cp/error.c
    branches/gcc-4_3-branch/gcc/cp/name-lookup.c
    branches/gcc-4_3-branch/gcc/testsuite/ChangeLog


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] [4.3 regression] Broken diagnostics for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
                   ` (4 preceding siblings ...)
  2008-03-06 17:52 ` [Bug c++/35338] [4.3 " paolo at gcc dot gnu dot org
@ 2008-03-06 17:53 ` pcarlini at suse dot de
  2008-12-24  3:47 ` [Bug c++/35338] Rejects valid code " pinskia at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: pcarlini at suse dot de @ 2008-03-06 17:53 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from pcarlini at suse dot de  2008-03-06 17:52 -------
Fixed for 4.3.1 too.


-- 

pcarlini at suse dot de changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED
   Target Milestone|4.3.0                       |4.3.1


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] Rejects valid code for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
                   ` (6 preceding siblings ...)
  2008-12-24  3:47 ` [Bug c++/35338] Rejects valid code " pinskia at gcc dot gnu dot org
@ 2008-12-24  3:47 ` pinskia at gcc dot gnu dot org
  2008-12-27 22:56 ` reichelt at gcc dot gnu dot org
  2009-02-19  7:24 ` [Bug c++/35338] [4.3/4.4 regression] Broken diagnostics " reichelt at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-12-24  3:47 UTC (permalink / raw)
  To: gcc-bugs



-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|paolo dot carlini at oracle |pinskia at gcc dot gnu dot
                   |dot com                     |org
             Status|REOPENED                    |ASSIGNED


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] Rejects valid code for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
                   ` (5 preceding siblings ...)
  2008-03-06 17:53 ` pcarlini at suse dot de
@ 2008-12-24  3:47 ` pinskia at gcc dot gnu dot org
  2008-12-24  3:47 ` pinskia at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  9 siblings, 0 replies; 11+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2008-12-24  3:47 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from pinskia at gcc dot gnu dot org  2008-12-24 03:45 -------
Why do you think this is invalid code?  The C front-end accepts this code.


I have a fix for:
bool b = !1r;


I am working on the fix for the first case.


-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |REOPENED
         Resolution|FIXED                       |
            Summary|[4.3 regression] Broken     |Rejects valid code for
                   |diagnostics for fixed-point |fixed-point types
                   |types                       |
   Target Milestone|4.3.1                       |---


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] Rejects valid code for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
                   ` (7 preceding siblings ...)
  2008-12-24  3:47 ` pinskia at gcc dot gnu dot org
@ 2008-12-27 22:56 ` reichelt at gcc dot gnu dot org
  2009-02-19  7:24 ` [Bug c++/35338] [4.3/4.4 regression] Broken diagnostics " reichelt at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2008-12-27 22:56 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from reichelt at gcc dot gnu dot org  2008-12-27 22:55 -------
> Why do you think this is invalid code?  The C front-end accepts this code.

Well, I believed the error messages - although I should know better than to
trust the compiler ;-)

It would be nice if you implemented the missing conversions. Thanks!


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

* [Bug c++/35338] [4.3/4.4 regression] Broken diagnostics for fixed-point types
  2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
                   ` (8 preceding siblings ...)
  2008-12-27 22:56 ` reichelt at gcc dot gnu dot org
@ 2009-02-19  7:24 ` reichelt at gcc dot gnu dot org
  9 siblings, 0 replies; 11+ messages in thread
From: reichelt at gcc dot gnu dot org @ 2009-02-19  7:24 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #8 from reichelt at gcc dot gnu dot org  2009-02-19 07:24 -------
Fixed-point constants are rejected by the C++ frontend since the patch for
PR39059. So lets turn the PR into the original state: a diagnostic issue
which has been fixed since GCC 4.3.1.


-- 

reichelt at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
           Keywords|rejects-valid               |diagnostic, monitored
         Resolution|                            |FIXED
            Summary|Rejects valid code for      |[4.3/4.4 regression] Broken
                   |fixed-point types           |diagnostics for fixed-point
                   |                            |types
   Target Milestone|---                         |4.3.1


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=35338


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2009-02-19  7:24 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-02-23 19:56 [Bug c++/35338] New: [4.3/4.4 regression] Broken diagnostics for fixed-point types reichelt at gcc dot gnu dot org
2008-02-23 19:56 ` [Bug c++/35338] " reichelt at gcc dot gnu dot org
2008-02-24 22:00 ` rguenth at gcc dot gnu dot org
2008-02-25 17:04 ` pcarlini at suse dot de
2008-02-25 19:06 ` paolo at gcc dot gnu dot org
2008-03-06 17:52 ` [Bug c++/35338] [4.3 " paolo at gcc dot gnu dot org
2008-03-06 17:53 ` pcarlini at suse dot de
2008-12-24  3:47 ` [Bug c++/35338] Rejects valid code " pinskia at gcc dot gnu dot org
2008-12-24  3:47 ` pinskia at gcc dot gnu dot org
2008-12-27 22:56 ` reichelt at gcc dot gnu dot org
2009-02-19  7:24 ` [Bug c++/35338] [4.3/4.4 regression] Broken diagnostics " reichelt at gcc dot gnu dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).