[Bug c++/101004] New: SFINAE constrained conversion operator of class template parameter type does not work with built-in arithmetic operators

2021-06-09 Thread namark at disroot dot org via Gcc-bugs
Version: 10.2.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: namark at disroot dot org Target Milestone: --- I believe the following code should be valid, but gcc

[Bug c++/87605] Ternary uses explicit copy constructor for lvalue-to-rvalue conversion

2018-10-13 Thread namark at disroot dot org
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=87605 --- Comment #2 from namark --- (In reply to Andrew Pinski from comment #1) > Except A() is a temp so it cannot be a lvalue. Not sure what you mean. As I understood 'a' is the lvalue, being converted to an rvalue by the ternary. I'm not very good

[Bug c++/87605] New: Ternary uses explicit copy constructor for lvalue-to-rvalue conversion

2018-10-13 Thread namark at disroot dot org
Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: namark at disroot dot org Target Milestone: --- The code below compiles and outputs "copy" to stdout when ran. #include struct A { A(){} explicit A(const A&am