[Bug c++/7221] wrong linkage of typedef-named classes
msebor at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Tue Feb 28 00:35:00 GMT 2017
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=7221
Martin Sebor <msebor at gcc dot gnu.org> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEW |RESOLVED
CC| |msebor at gcc dot gnu.org
Resolution|--- |FIXED
--- Comment #7 from Martin Sebor <msebor at gcc dot gnu.org> ---
This works correctly in recent GCC versions. Resolving as fixed.
$ cat t.C && gcc -S -Wall -Wextra -Wpedantic -o/dev/stdout t.C
typedef struct {
void foo ();
} S;
void S::foo () { }
.file "t.C"
.text
.align 2
.globl _ZN1S3fooEv
.type _ZN1S3fooEv, @function
_ZN1S3fooEv:
.LFB0:
.cfi_startproc
pushq %rbp
.cfi_def_cfa_offset 16
.cfi_offset 6, -16
movq %rsp, %rbp
.cfi_def_cfa_register 6
movq %rdi, -8(%rbp)
nop
popq %rbp
.cfi_def_cfa 7, 8
ret
.cfi_endproc
.LFE0:
.size _ZN1S3fooEv, .-_ZN1S3fooEv
.ident "GCC: (GNU) 7.0.1 20170223 (experimental)"
.section .note.GNU-stack,"",@progbits
More information about the Gcc-bugs
mailing list