[Bug c++/100976] [C++23] Make constexpr reference temp constexpr

2021-07-19 Thread mpolacek at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100976 Marek Polacek changed: What|Removed |Added Resolution|--- |WORKSFORME Status|ASSIGNED

[Bug c++/100976] [C++23] Make constexpr reference temp constexpr

2021-07-01 Thread mpolacek at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100976 --- Comment #3 from Marek Polacek --- (In reply to Jason Merrill from comment #2) > Or rather, > > int main() > { > constexpr const int &r = 42; > static_assert(r == 42); // { dg-bogus "" } > } > > [expr.const]/4.7 says that "a temporary o

[Bug c++/100976] [C++23] Make constexpr reference temp constexpr

2021-07-01 Thread mpolacek at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100976 Marek Polacek changed: What|Removed |Added Assignee|unassigned at gcc dot gnu.org |mpolacek at gcc dot gnu.org

[Bug c++/100976] [C++23] Make constexpr reference temp constexpr

2021-06-08 Thread jason at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100976 --- Comment #2 from Jason Merrill --- Or rather, int main() { constexpr const int &r = 42; static_assert(r == 42); // { dg-bogus "" } } [expr.const]/4.7 says that "a temporary object of non-volatile const-qualified literal type whose lifet

[Bug c++/100976] [C++23] Make constexpr reference temp constexpr

2021-06-08 Thread jason at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100976 --- Comment #1 from Jason Merrill --- constexpr const int &r = 42; static_assert(r == 42);

[Bug c++/100976] [C++23] Make constexpr reference temp constexpr

2021-06-08 Thread mpolacek at gcc dot gnu.org via Gcc-bugs
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=100976 Marek Polacek changed: What|Removed |Added Status|UNCONFIRMED |NEW Ever confirmed|0