http://gcc.gnu.org/bugzilla/show_bug.cgi?id=51724
Bug #: 51724
Summary: no matching function for call; confused by earlier
errors, bailing out
Classification: Unclassified
Product: gcc
Version: 4.6.2
Status:
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=52109
Bug #: 52109
Summary: Apparently endless recursive instantiation
Classification: Unclassified
Product: gcc
Version: 4.6.2
Status: UNCONFIRMED
Severity: normal
++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
$ gcc --version
gcc (Ubuntu 4.8.4-2ubuntu1~14.04) 4.8.4
$ cat voidptr
void foo(void *p)
{
typeof(*p) *x;
}
I'd expect this to work as if 'x' was declared 'void *x' (which
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67582
--- Comment #3 from Vegard Nossum ---
(In reply to Jonathan Wakely from comment #1)
> You can't dereference a void*, so why do you expect to be able to get the
> type of an invalid expression?
I was under the impression that the expression was
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67582
--- Comment #5 from Vegard Nossum ---
(In reply to Jonathan Wakely from comment #4)
> But *p is not a valid expression, so you might as well ask for
> typeof(this is nonsense and not valid C++).
>
> You also can't ask for sizeof(*p) for a void
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Using this:
struct t {
template
t(F &)
{
}
};
void foo()
{
(t([const ]() { i
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
The following is obviously not a valid C++ program but crashes the compiler:
a(){[](class{
Output:
:1:3: error: ISO C++ forbids
: ice-on-invalid-code
Severity: normal
Priority: P3
Component: inline-asm
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Created attachment 43580
--> https://gcc.gnu.org/bugzilla/attachment.
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
void a() {
alignof(({
b: 0;
}));
goto b;
}
Output:
$ xgcc -x c
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84742
--- Comment #4 from Vegard Nossum ---
So I think the problem is that this loop in lra_set_insn_recog_data() counts
the number of commas and uses that as the number of alternatives:
1018 for (p = constraints[0]; *p; p++)
1019
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84742
--- Comment #2 from Vegard Nossum ---
Created attachment 43598
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=43598=edit
ASAN output
I compiled gcc itself using -fstack-protector-all -fsanitize=address and it
occasionally gives me the
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84742
--- Comment #3 from Vegard Nossum ---
gcc/recog.c:2395 is:
2390 case '0': case '1': case '2': case '3': case '4':
2391 case '5': case '6': case '7': case '8': case '9':
2392 {
2393 char *end;
2394 op_alt[i].matches = strtoul (p, ,
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input (I know... don't ask):
template __attribute__ a([] { class c,
__attribute__(vector_size(operator+( d;
Output
: 8.0.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
template
void b(int c) {
static_assert(c
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=39751
Vegard Nossum changed:
What|Removed |Added
CC||vegard.nossum at gmail dot com
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
struct {
struct {
class a;
}; : a
} x;
Output:
$ xgcc -x c++ -std=c++14 -O3 -c - 2>&1
:4:8: internal c
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84632
--- Comment #2 from Vegard Nossum ---
(In reply to Marek Polacek from comment #1)
> Can't reproduce this one with r258080.
I just recompiled r258097 and I still get it:
$ xgcc -x c++ -S -
[...]
:3:9: internal compiler error: tree check:
Version: 8.0.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
I was quite sure I had submitted this one
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
a(int(const &&__attribute__((b(auto;)
Output:
:1:36: internal compil
: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
typedef void a();
struct {
a: 1;
};
Output:
$ xgcc -x c++ -S -
:3:6: internal compiler error: Segmentation
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
a(volatile int b) { }
Output:
$ xgcc -x c++ -S -fpermissive -fsanitize=address -
:1:17: warning
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
template
struct b {
decltype(a) __attribute__((break));
};
Output:
$ xgcc -x c++ -S -
:3:35
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84633
--- Comment #2 from Vegard Nossum ---
(In reply to Marek Polacek from comment #1)
> (In reply to Vegard Nossum from comment #0)
> > 7.3.0 seems fine.
>
> I think you're testing with a compiler built with --enable-checking=release
> so it
, at
cp/constexpr.c:1778
Product: gcc
Version: 8.0.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
a (void[sizeof(0 = auto)]);
Output:
$ xgcc -x c++ -S -fpermissive -
:1:20: error: expected primary-expression before 'auto'
:1:19
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
void (*a)(auto b = c());
Output:
xgcc -x c++ -S -fpermissive -
:1:20: warning: there are no arguments to 'c' that depend
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
void a() {
struct {
int b struct b
} x;
}
Output:
$ xgcc -x c++ -S -
: In function 'void a()':
:3:9: error
: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
struct {
int
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71572
Vegard Nossum changed:
What|Removed |Added
CC||vegard.nossum at gmail dot com
-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
struct c {
~c();
} b;
void f
Status: UNCONFIRMED
Keywords: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=71485
Vegard Nossum changed:
What|Removed |Added
CC||vegard.nossum at gmail dot com
-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
struct a {
void b() {
struct c
-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
int b;
void c() {
struct
Version: 8.0.1
Status: UNCONFIRMED
Keywords: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp
Keywords: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
a(__attribute__((b
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
void a() { a[0]() }
Output:
$ cc1plus
-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
template
struct a {
unsigned b
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=81575
Vegard Nossum changed:
What|Removed |Added
CC||vegard.nossum at gmail dot com
Product: gcc
Version: 8.0.1
Status: UNCONFIRMED
Keywords: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84596
--- Comment #6 from Vegard Nossum ---
I see a similar ICE on r258221 using this test case:
template
struct a {
constexpr int b() {
int c;
static_assert(c %= 1);
}
};
Output:
$ xgcc -x c++ -S -
: In member function 'constexpr int
: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input (this one is positively
++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
int a[]{0};
void b() {
a[({0;})] %= 0;
}
Output:
$ xgcc -x c++ -S -g -O3 -
: In function 'void b
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
void a();
namespace {
void a();
}
template
void
: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
template
void
-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
int a[]{a};
template
struct b
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84704
--- Comment #1 from Vegard Nossum ---
I should add that both -g and (one of) -Os/-O1/-O2/-O3 seems necessary for the
ICE to trigger. Also, it seems that 7.3.0 works by emitting this for -O1:
b():
mov eax, DWORD PTR a[rip]
mov ecx, 0
cdq
: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
int y;
void a() {
struct {
int b = ([] {
decltype(b) x
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84651
--- Comment #2 from Vegard Nossum ---
Related test case/crash:
void a() {
struct {
void b(float) struct b = 0;
void b();
} x;
}
int b;
Gives:
xgcc -x c++ -S -
: In function 'void a()':
:3:17: error: expected ';' at end of member
Product: gcc
Version: 8.0.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
int __builtin_trap();
int
-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
void a(struct b ) {
asm ("&q
: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input (you gotta love this one!):
template
struct b {
int &
int d[] = [] { auto f(a); };
} const __attribu
Priority: P3
Component: inline-asm
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
void a() {
double b;
asm ("" : "+pz, y" (b));
}
Output:
$ xgcc -x c++ -S -
: In funct
: UNCONFIRMED
Severity: normal
Priority: P3
Component: inline-asm
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
void f() {
int b;
asm("" : "=mp" (b));
(void)
}
-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
int a;
void b(__attribute__((c([](int
Severity: normal
Priority: P3
Component: inline-asm
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
void a() {
double b;
asm volatile("" : "=vp" (b) : "0"
Priority: P3
Component: inline-asm
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
void b(char a) {
asm("" : : "pIr" (a));
}
Output:
$ xgcc -x c++ -S -Wall -
dur
Priority: P3
Component: inline-asm
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
void a(float b, double c) {
for (int e = 0; e < 2; e++) {
asm volatile ("" : "+f" (
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84682
--- Comment #2 from Vegard Nossum ---
I'm also seeing a different crash with this (using -O3):
int a;
void b() {
float c;
for (int d; d;)
;
a = c;
asm("" : : "pIr"(c));
}
Output:
$ xgcc -x c++ -S -Wall -fpermissive -O3 -
: In
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
This program:
struct a {
void b() {}
void c(auto = [] {
if (a a(int auto){})
;
}) {}
};
Invoked with:
xgcc -x
Product: gcc
Version: 8.0.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
void a() {
struct
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
This (invalid) program:
template b() {[](auto = template <;{a c(auto
When compiled with:
xgcc -x c++ -std=c++14 -O3
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84576
--- Comment #4 from Vegard Nossum ---
(In reply to Jakub Jelinek from comment #3)
> BTW, when using creduce, if the original is valid or has just one error or
> something similar, please try to write the script such that it will not
> confirm a
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
struct a {
int x;
int c = 0;
int
} c = {};
Output:
$ xgcc -x c++ -std=c++14 -O3 -c -
:5:8: error: member 'a::b
: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
template
struct s {
struct {
void __attribute__((common([] { struct d }))) g();
} f;
};
s a {};
Output
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Created attachment 43525
--> https://gcc.gnu.org/bugzilla/attachment.cgi?id=43525=edit
GDB stack trace
Input:
void f(v
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
struct s {
int a __attribute__((aligned([](char *) {})));
};
Output:
$ xgcc -x c++ -std=c++14 -O3 -Wall
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84576
--- Comment #5 from Vegard Nossum ---
I have another testcase which crashes in a similar way, but I'm not sure if
it's the same underlying bug or not:
void a() {
enum * {
[] (union {})
};
}
The original crash was:
(gdb) run
Starting
: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
a (int &__attribute__ ((aligned(auto x)) y));
Output:
$ xgcc -x c++ -c inpu
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
template
void a() {
struct {
void b() const;
void b() { [b] }
};
};
Output:
$ xgcc -x c++ -S input.cc
Version: 8.0.1
Status: UNCONFIRMED
Keywords: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot
: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
int a() {
auto = 1
-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
class {
b(decltype(((a = 0
-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
struct {
} a[1];
template
void b
/typeck.c:1944
Product: gcc
Version: 8.0.1
Status: UNCONFIRMED
Keywords: ice-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail
Severity: normal
Priority: P3
Component: demangler
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
$ c++filt '__H5z55_H5z555'
c++filt: out of memory allocating
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
template
int a(a);
Output:
$ xgcc -x c++ -S -
:2:17: error: types may not be defined in template arguments
:2:19
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
constexpr int a();
b(int, __attribute__((c(int{} && (a == (auto) (a););
Output:
xgcc -x c++ -S -
:2:50: error:
: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
template
struct a {
a() {
struct c;
try {
} catch (struct c {}) {
}
}
};
struct d {
d
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
Target Milestone: ---
Input:
struct b {
x(((struct b {})));
};
Output:
$ xgcc -x c++ -std=c++14 -O3 -c -
:2:4: error: expected identifier before
-on-invalid-code
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
void a(int b) {
asm(""
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: vegard.nossum at gmail dot com
CC: webrown.cpp at gmail dot com
Target Milestone: ---
Input:
typedef int b[2];
void a() {
new b(a);
}
Output:
$ xgcc -x c++ -S -std
83 matches
Mail list logo