[Bug c++/78615] error: cannot decrement a pointer to incomplete type

2019-05-15 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78615

--- Comment #6 from Jonathan Wakely  ---
Oh no, the destructor isn't instantiated here. So I guess the structure type
*could* be complete where the destructor is instantiated.

Possibly still "ill-formed; no diagnostic required" but I'm no longer certain.

[Bug c++/78615] error: cannot decrement a pointer to incomplete type

2019-05-15 Thread redi at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78615

--- Comment #5 from Jonathan Wakely  ---
Definitely invalid. The type is incomplete at the point of instantiation.

[Bug c++/78615] error: cannot decrement a pointer to incomplete type

2019-05-14 Thread mpolacek at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78615

Marek Polacek  changed:

   What|Removed |Added

 CC||mpolacek at gcc dot gnu.org

--- Comment #4 from Marek Polacek  ---
This is again accepted starting with r245612.  I haven't figured out yet if
it's valid or not (and whether we should add the test).

[Bug c++/78615] error: cannot decrement a pointer to incomplete type

2016-12-01 Thread rguenth at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78615

Richard Biener  changed:

   What|Removed |Added

Version|unknown |7.0

--- Comment #3 from Richard Biener  ---
Yeah, I think this is not valid code.

[Bug c++/78615] error: cannot decrement a pointer to incomplete type

2016-11-30 Thread pinskia at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78615

--- Comment #2 from Andrew Pinski  ---
I don't think this is valid code and here is why:
struct QListNode is incomplete.
You use an instantiation of QList via class B which means all methods of
QList are instantiated.

[Bug c++/78615] error: cannot decrement a pointer to incomplete type

2016-11-30 Thread marxin at gcc dot gnu.org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=78615

Martin Liška  changed:

   What|Removed |Added

  Known to work||5.4.0, 6.2.0
  Known to fail||7.0

--- Comment #1 from Martin Liška  ---
clang++ 3.8.1 accepts the code.