: other
Assignee: unassigned at gcc dot gnu.org
Reporter: palves at redhat dot com
The fix for bug 59195 (C++ demangler handles conversion operator incorrectly)
makes the demangler crash crash due to infinite recursion, in case of casts in
template parameters. For example
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59195
Pedro Alves changed:
What|Removed |Added
CC||palves at redhat dot com
--- Comment #4
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59195
--- Comment #5 from Pedro Alves ---
Likely bug 61233 too.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61321
--- Comment #1 from Pedro Alves ---
I think we need to distinguish conversion operators from expression casts.
Working on a patch that adds:
--- c/include/demangle.h
+++ w/include/demangle.h
@@ -373,6 +373,10 @@ enum demangle_component_type
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61321
--- Comment #2 from Pedro Alves ---
That worked. Running bootstrap/tests.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61321
--- Comment #3 from Pedro Alves ---
https://gcc.gnu.org/ml/gcc-patches/2014-05/msg02279.html
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61233
--- Comment #2 from Pedro Alves ---
This fixes it:
https://gcc.gnu.org/ml/gcc-patches/2014-05/msg02279.html
See bug 61321.
IRMED
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: palves at redhat dot com
Target Milestone: ---
With:
$ gcc6 -v:
...
GNU C11 (GCC) version 6.0.0 20151117 (experimental) (x86_64-pc-linux-gnu)
...
This warn
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68582
--- Comment #1 from Pedro Alves ---
Same thing with gcc version 4.8.3 20140911 (Red Hat 4.8.3-7) (GCC) [Fedora 20].
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=61321
--- Comment #8 from Pedro Alves ---
The patch was meanwhile approved:
https://gcc.gnu.org/ml/gcc-patches/2014-11/msg01247.html
I'm afraid I won't have time to get back to this for at least a few weeks.
If someone else could push it, I'd apprec
Severity: normal
Priority: P3
Component: c
Assignee: unassigned at gcc dot gnu.org
Reporter: palves at redhat dot com
Target Milestone: ---
gcc does not understand that adding an offset to a pointer returned by a
returns_nonnull function can never
Assignee: unassigned at gcc dot gnu.org
Reporter: palves at redhat dot com
Target Milestone: ---
This testcase makes gcc issue a confusing warning:
$ cat strtok.c
char *xstrdup (const char *) __attribute__ ((__returns_nonnull__));
#define PREFIX "some "
#inc
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71701
--- Comment #1 from Pedro Alves ---
I tried to reduce this manually, but failed. My attempt made gcc warn about
the original variable in my test case:
strtok.c: In function ‘main’:
strtok.h:30:10: warning: ‘saveptr’ may be used uninitialized
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71701
--- Comment #2 from Pedro Alves ---
Created attachment 38790
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38790&action=edit
Testcase.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71701
--- Comment #3 from Pedro Alves ---
Created attachment 38791
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38791&action=edit
Preprocessed testcase.
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71701
--- Comment #4 from Pedro Alves ---
This was with: gcc version 7.0.0 20160503 (experimental) (GCC)
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71701
--- Comment #5 from Pedro Alves ---
See original context here, where the warning was truly puzzling:
https://sourceware.org/ml/gdb-patches/2016-06/msg00515.html
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71699
--- Comment #1 from Pedro Alves ---
Created attachment 38792
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=38792&action=edit
Testcase.
101 - 118 of 118 matches
Mail list logo