public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/39208]  New: Incorrect mangled name for function as template argument
@ 2009-02-16 22:07 dgregor at gcc dot gnu dot org
  2009-02-16 22:28 ` [Bug c++/39208] " pinskia at gmail dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: dgregor at gcc dot gnu dot org @ 2009-02-16 22:07 UTC (permalink / raw)
  To: gcc-bugs

Given the following code:

  template<int (&p)(int, int)> struct X { };
  int f(int, int) { }
  void g(X<f>) { }

GCC produces the mangled name:

  _Z1g1XILZ1fiiEE

for the function 'g'. However, the correct mangled name is:

  _Z1g1XIL_Z1fiiEE

GCC is missing the '_' prior to the 'Z' in the mangled name of the template
argument 'f'.


-- 
           Summary: Incorrect mangled name for function as template argument
           Product: gcc
           Version: 4.3.3
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dgregor at gcc dot gnu dot org


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


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

* [Bug c++/39208] Incorrect mangled name for function as template argument
  2009-02-16 22:07 [Bug c++/39208] New: Incorrect mangled name for function as template argument dgregor at gcc dot gnu dot org
@ 2009-02-16 22:28 ` pinskia at gmail dot com
  2009-02-16 22:28 ` [Bug c++/39208] New: " Andrew Thomas Pinski
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: pinskia at gmail dot com @ 2009-02-16 22:28 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from pinskia at gmail dot com  2009-02-16 22:28 -------
Subject: Re:   New: Incorrect mangled name for function as template argument

Yes this known I forgot the bug number but try with -fabi-version=0.

Sent from my iPhone

On Feb 16, 2009, at 2:07 PM, "dgregor at gcc dot gnu dot org"
<gcc-bugzilla@gcc.gnu.org 
 > wrote:

> Given the following code:
>
>  template<int (&p)(int, int)> struct X { };
>  int f(int, int) { }
>  void g(X<f>) { }
>
> GCC produces the mangled name:
>
>  _Z1g1XILZ1fiiEE
>
> for the function 'g'. However, the correct mangled name is:
>
>  _Z1g1XIL_Z1fiiEE
>
> GCC is missing the '_' prior to the 'Z' in the mangled name of the  
> template
> argument 'f'.
>
>
> -- 
>           Summary: Incorrect mangled name for function as template  
> argument
>           Product: gcc
>           Version: 4.3.3
>            Status: UNCONFIRMED
>          Severity: normal
>          Priority: P3
>         Component: c++
>        AssignedTo: unassigned at gcc dot gnu dot org
>        ReportedBy: dgregor at gcc dot gnu dot org
>
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39208
>


-- 


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


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

* Re: [Bug c++/39208]  New: Incorrect mangled name for function as template argument
  2009-02-16 22:07 [Bug c++/39208] New: Incorrect mangled name for function as template argument dgregor at gcc dot gnu dot org
  2009-02-16 22:28 ` [Bug c++/39208] " pinskia at gmail dot com
@ 2009-02-16 22:28 ` Andrew Thomas Pinski
  2009-02-16 22:37 ` [Bug c++/39208] " dgregor at gcc dot gnu dot org
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: Andrew Thomas Pinski @ 2009-02-16 22:28 UTC (permalink / raw)
  To: gcc-bugzilla; +Cc: gcc-bugs

Yes this known I forgot the bug number but try with -fabi-version=0.

Sent from my iPhone

On Feb 16, 2009, at 2:07 PM, "dgregor at gcc dot gnu dot org" <gcc-bugzilla@gcc.gnu.org 
 > wrote:

> Given the following code:
>
>  template<int (&p)(int, int)> struct X { };
>  int f(int, int) { }
>  void g(X<f>) { }
>
> GCC produces the mangled name:
>
>  _Z1g1XILZ1fiiEE
>
> for the function 'g'. However, the correct mangled name is:
>
>  _Z1g1XIL_Z1fiiEE
>
> GCC is missing the '_' prior to the 'Z' in the mangled name of the  
> template
> argument 'f'.
>
>
> -- 
>           Summary: Incorrect mangled name for function as template  
> argument
>           Product: gcc
>           Version: 4.3.3
>            Status: UNCONFIRMED
>          Severity: normal
>          Priority: P3
>         Component: c++
>        AssignedTo: unassigned at gcc dot gnu dot org
>        ReportedBy: dgregor at gcc dot gnu dot org
>
>
> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=39208
>


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

* [Bug c++/39208] Incorrect mangled name for function as template argument
  2009-02-16 22:07 [Bug c++/39208] New: Incorrect mangled name for function as template argument dgregor at gcc dot gnu dot org
  2009-02-16 22:28 ` [Bug c++/39208] " pinskia at gmail dot com
  2009-02-16 22:28 ` [Bug c++/39208] New: " Andrew Thomas Pinski
@ 2009-02-16 22:37 ` dgregor at gcc dot gnu dot org
  2009-02-16 22:40 ` jakub at gcc dot gnu dot org
  2009-02-16 22:41 ` jakub at gcc dot gnu dot org
  4 siblings, 0 replies; 6+ messages in thread
From: dgregor at gcc dot gnu dot org @ 2009-02-16 22:37 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #2 from dgregor at gcc dot gnu dot org  2009-02-16 22:37 -------
You're right: it works with -fabi-version is 0. Closing as invalid.


-- 

dgregor at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID


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


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

* [Bug c++/39208] Incorrect mangled name for function as template argument
  2009-02-16 22:07 [Bug c++/39208] New: Incorrect mangled name for function as template argument dgregor at gcc dot gnu dot org
                   ` (2 preceding siblings ...)
  2009-02-16 22:37 ` [Bug c++/39208] " dgregor at gcc dot gnu dot org
@ 2009-02-16 22:40 ` jakub at gcc dot gnu dot org
  2009-02-16 22:41 ` jakub at gcc dot gnu dot org
  4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu dot org @ 2009-02-16 22:40 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #3 from jakub at gcc dot gnu dot org  2009-02-16 22:40 -------
Reopening...


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|RESOLVED                    |UNCONFIRMED
         Resolution|INVALID                     |


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


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

* [Bug c++/39208] Incorrect mangled name for function as template argument
  2009-02-16 22:07 [Bug c++/39208] New: Incorrect mangled name for function as template argument dgregor at gcc dot gnu dot org
                   ` (3 preceding siblings ...)
  2009-02-16 22:40 ` jakub at gcc dot gnu dot org
@ 2009-02-16 22:41 ` jakub at gcc dot gnu dot org
  4 siblings, 0 replies; 6+ messages in thread
From: jakub at gcc dot gnu dot org @ 2009-02-16 22:41 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #4 from jakub at gcc dot gnu dot org  2009-02-16 22:41 -------
to close as dup of PR16240.

*** This bug has been marked as a duplicate of 16240 ***


-- 

jakub at gcc dot gnu dot org changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |DUPLICATE


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


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

end of thread, other threads:[~2009-02-16 22:41 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-02-16 22:07 [Bug c++/39208] New: Incorrect mangled name for function as template argument dgregor at gcc dot gnu dot org
2009-02-16 22:28 ` [Bug c++/39208] " pinskia at gmail dot com
2009-02-16 22:28 ` [Bug c++/39208] New: " Andrew Thomas Pinski
2009-02-16 22:37 ` [Bug c++/39208] " dgregor at gcc dot gnu dot org
2009-02-16 22:40 ` jakub at gcc dot gnu dot org
2009-02-16 22:41 ` 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).