[Bug c++/95808] New: Can mismatch non-array new/delete with array new/delete during constant evaluation
johelegp at gmail dot com
gcc-bugzilla@gcc.gnu.org
Mon Jun 22 03:22:19 GMT 2020
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95808
Bug ID: 95808
Summary: Can mismatch non-array new/delete with array
new/delete during constant evaluation
Product: gcc
Version: 10.1.0
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: c++
Assignee: unassigned at gcc dot gnu.org
Reporter: johelegp at gmail dot com
Target Milestone: ---
See https://godbolt.org/z/ZHiKmm.
```C++
constexpr void f()
{
delete[] new int;
delete new int[1];
}
constexpr int x{([]() consteval { f(); }(), 0)};
```
More information about the Gcc-bugs
mailing list