public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c/45079]  New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression')
@ 2010-07-26 14:15 doko at ubuntu dot com
  2010-07-26 14:47 ` [Bug c/45079] " jakub at gcc dot gnu dot org
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: doko at ubuntu dot com @ 2010-07-26 14:15 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 1095 bytes --]

4.4 doesn't print the function names in the error message, while 4.5 and 4.6 do
so:

$ cat  foo.c
void foo(const char *p, int cond, int a, int b)
{
        p[cond ? a : b] = '\0';
}

$ gcc-4.4 -c foo.c
foo.c: In function 'foo':
foo.c:3: error: assignment of read-only location '*(p + (cond != 0 ? (long
unsigned int)(long unsigned int)a : (long unsigned int)(long unsigned int)b))'

$ gcc-4.5 -c foo.c
#'c_maybe_const_expr' not supported by pp_c_expression#) != 0 ? (long unsigned
int)a : (long unsigned int)b) * 1ul))'foo.c: In function 'foo':
foo.c:3:2: error: assignment of read-only location

is the new format expected?


-- 
           Summary: function names in error message
                    (�c_maybe_const_expr� not supported by
                    'pp_c_expression')
           Product: gcc
           Version: 4.5.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: doko at ubuntu dot com


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


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

* [Bug c/45079] function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression')
  2010-07-26 14:15 [Bug c/45079] New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression') doko at ubuntu dot com
@ 2010-07-26 14:47 ` jakub at gcc dot gnu dot org
  2010-07-27  6:50 ` [Bug c/45079] [4.5/4.6 Regression] " pinskia at gcc dot gnu dot org
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: jakub at gcc dot gnu dot org @ 2010-07-26 14:47 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from jakub at gcc dot gnu dot org  2010-07-26 14:47 -------
Created an attachment (id=21317)
 --> (http://gcc.gnu.org/bugzilla/attachment.cgi?id=21317&action=view)
gcc46-pr45079.patch

Untested fix.


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
         AssignedTo|unassigned at gcc dot gnu   |jakub at gcc dot gnu dot org
                   |dot org                     |
             Status|UNCONFIRMED                 |ASSIGNED


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


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

* [Bug c/45079] [4.5/4.6 Regression] function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression')
  2010-07-26 14:15 [Bug c/45079] New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression') doko at ubuntu dot com
  2010-07-26 14:47 ` [Bug c/45079] " jakub at gcc dot gnu dot org
@ 2010-07-27  6:50 ` pinskia at gcc dot gnu dot org
  2010-07-27 15:47 ` jakub at gcc dot gnu dot org
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: pinskia at gcc dot gnu dot org @ 2010-07-27  6:50 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 709 bytes --]



-- 

pinskia at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|function names in error     |[4.5/4.6 Regression]
                   |message                     |function names in error
                   |(�c_maybe_const_expr�   |message
                   |not supported by            |(�c_maybe_const_expr�
                   |'pp_c_expression')          |not supported by
                   |                            |'pp_c_expression')
   Target Milestone|---                         |4.5.1


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


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

* [Bug c/45079] [4.5/4.6 Regression] function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression')
  2010-07-26 14:15 [Bug c/45079] New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression') doko at ubuntu dot com
  2010-07-26 14:47 ` [Bug c/45079] " jakub at gcc dot gnu dot org
  2010-07-27  6:50 ` [Bug c/45079] [4.5/4.6 Regression] " pinskia at gcc dot gnu dot org
@ 2010-07-27 15:47 ` jakub at gcc dot gnu dot org
  2010-07-27 15:50 ` [Bug c/45079] [4.5 " jakub at gcc dot gnu dot org
                   ` (4 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: jakub at gcc dot gnu dot org @ 2010-07-27 15:47 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from jakub at gcc dot gnu dot org  2010-07-27 15:46 -------
Subject: Bug 45079

Author: jakub
Date: Tue Jul 27 15:46:25 2010
New Revision: 162575

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=162575
Log:
        PR c/45079
        * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.

        * gcc.dg/pr45079.c: New test.

Added:
    trunk/gcc/testsuite/gcc.dg/pr45079.c
Modified:
    trunk/gcc/c-family/ChangeLog
    trunk/gcc/c-family/c-pretty-print.c
    trunk/gcc/testsuite/ChangeLog


-- 


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


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

* [Bug c/45079] [4.5 Regression] function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression')
  2010-07-26 14:15 [Bug c/45079] New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression') doko at ubuntu dot com
                   ` (2 preceding siblings ...)
  2010-07-27 15:47 ` jakub at gcc dot gnu dot org
@ 2010-07-27 15:50 ` jakub at gcc dot gnu dot org
  2010-07-31  9:35 ` rguenth at gcc dot gnu dot org
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: jakub at gcc dot gnu dot org @ 2010-07-27 15:50 UTC (permalink / raw)
  To: gcc-bugs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 917 bytes --]



------- Comment #3 from jakub at gcc dot gnu dot org  2010-07-27 15:50 -------
Fixed on the trunk so far, with 4.5 will wait until 4.5.1 is released.


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Known to fail|4.5.0 4.6.0                 |4.5.0
      Known to work|4.4.4                       |4.4.4 4.6.0
            Summary|[4.5/4.6 Regression]        |[4.5 Regression] function
                   |function names in error     |names in error message
                   |message                     |(�c_maybe_const_expr�
                   |(�c_maybe_const_expr�   |not supported by
                   |not supported by            |'pp_c_expression')
                   |'pp_c_expression')          |


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


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

* [Bug c/45079] [4.5 Regression] function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression')
  2010-07-26 14:15 [Bug c/45079] New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression') doko at ubuntu dot com
                   ` (3 preceding siblings ...)
  2010-07-27 15:50 ` [Bug c/45079] [4.5 " jakub at gcc dot gnu dot org
@ 2010-07-31  9:35 ` rguenth at gcc dot gnu dot org
  2010-08-30 15:52 ` rguenth at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-07-31  9:35 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from rguenth at gcc dot gnu dot org  2010-07-31 09:30 -------
GCC 4.5.1 is being released, adjusting target milestone.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|4.5.1                       |4.5.2


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


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

* [Bug c/45079] [4.5 Regression] function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression')
  2010-07-26 14:15 [Bug c/45079] New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression') doko at ubuntu dot com
                   ` (4 preceding siblings ...)
  2010-07-31  9:35 ` rguenth at gcc dot gnu dot org
@ 2010-08-30 15:52 ` rguenth at gcc dot gnu dot org
  2010-08-30 19:32 ` jakub at gcc dot gnu dot org
  2010-08-30 19:34 ` jakub at gcc dot gnu dot org
  7 siblings, 0 replies; 9+ messages in thread
From: rguenth at gcc dot gnu dot org @ 2010-08-30 15:52 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #5 from rguenth at gcc dot gnu dot org  2010-08-30 15:52 -------
Jakub, ping.


-- 

rguenth at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
           Priority|P3                          |P2


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


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

* [Bug c/45079] [4.5 Regression] function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression')
  2010-07-26 14:15 [Bug c/45079] New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression') doko at ubuntu dot com
                   ` (5 preceding siblings ...)
  2010-08-30 15:52 ` rguenth at gcc dot gnu dot org
@ 2010-08-30 19:32 ` jakub at gcc dot gnu dot org
  2010-08-30 19:34 ` jakub at gcc dot gnu dot org
  7 siblings, 0 replies; 9+ messages in thread
From: jakub at gcc dot gnu dot org @ 2010-08-30 19:32 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #6 from jakub at gcc dot gnu dot org  2010-08-30 19:32 -------
Subject: Bug 45079

Author: jakub
Date: Mon Aug 30 19:31:45 2010
New Revision: 163657

URL: http://gcc.gnu.org/viewcvs?root=gcc&view=rev&rev=163657
Log:
        Backport from mainline
        2010-07-27  Jakub Jelinek  <jakub@redhat.com>

        PR c/45079
        * c-pretty-print.c (pp_c_expression): Handle C_MAYBE_CONST_EXPR.

        * gcc.dg/pr45079.c: New test.

Added:
    branches/gcc-4_5-branch/gcc/testsuite/gcc.dg/pr45079.c
Modified:
    branches/gcc-4_5-branch/gcc/ChangeLog
    branches/gcc-4_5-branch/gcc/c-pretty-print.c
    branches/gcc-4_5-branch/gcc/testsuite/ChangeLog


-- 


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


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

* [Bug c/45079] [4.5 Regression] function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression')
  2010-07-26 14:15 [Bug c/45079] New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression') doko at ubuntu dot com
                   ` (6 preceding siblings ...)
  2010-08-30 19:32 ` jakub at gcc dot gnu dot org
@ 2010-08-30 19:34 ` jakub at gcc dot gnu dot org
  7 siblings, 0 replies; 9+ messages in thread
From: jakub at gcc dot gnu dot org @ 2010-08-30 19:34 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #7 from jakub at gcc dot gnu dot org  2010-08-30 19:33 -------
Fixed, sorry for the delay.


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|ASSIGNED                    |RESOLVED
         Resolution|                            |FIXED


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


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

end of thread, other threads:[~2010-08-30 19:34 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-07-26 14:15 [Bug c/45079] New: function names in error message (�c_maybe_const_expr� not supported by 'pp_c_expression') doko at ubuntu dot com
2010-07-26 14:47 ` [Bug c/45079] " jakub at gcc dot gnu dot org
2010-07-27  6:50 ` [Bug c/45079] [4.5/4.6 Regression] " pinskia at gcc dot gnu dot org
2010-07-27 15:47 ` jakub at gcc dot gnu dot org
2010-07-27 15:50 ` [Bug c/45079] [4.5 " jakub at gcc dot gnu dot org
2010-07-31  9:35 ` rguenth at gcc dot gnu dot org
2010-08-30 15:52 ` rguenth at gcc dot gnu dot org
2010-08-30 19:32 ` jakub at gcc dot gnu dot org
2010-08-30 19:34 ` jakub 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).