[Bug c++/92752] [9/10/11/12 Regression] Bogus "ignored qualifiers" warning on const-qualified pointer-to-member-function objects
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92752 --- Comment #2 from CVS Commits --- The master branch has been updated by Patrick Palka : https://gcc.gnu.org/g:e971990cbda091b4caf5e1a5bded5121068934e4 commit r12-6926-ge971990cbda091b4caf5e1a5bded5121068934e4 Author: Patrick Palka Date: Fri Jan 28 15:41:15 2022 -0500 c++: bogus warning with value init of const pmf [PR92752] Here we're emitting a -Wignored-qualifiers warning for an intermediate compiler-generated cast of nullptr to 'method-type* const' as part of value initialization of a const pmf. This patch suppresses the warning by instead casting to the corresponding unqualified type. PR c++/92752 gcc/cp/ChangeLog: * typeck.cc (build_ptrmemfunc): Cast a nullptr constant to the unqualified pointer type not the qualified one. gcc/testsuite/ChangeLog: * g++.dg/warn/Wignored-qualifiers2.C: New test. Co-authored-by: Jason Merrill
[Bug c++/92752] [9/10/11/12 Regression] Bogus "ignored qualifiers" warning on const-qualified pointer-to-member-function objects
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92752 Patrick Palka changed: What|Removed |Added Status|NEW |ASSIGNED Assignee|unassigned at gcc dot gnu.org |ppalka at gcc dot gnu.org
[Bug c++/92752] [9/10/11/12 Regression] Bogus "ignored qualifiers" warning on const-qualified pointer-to-member-function objects
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92752 Richard Biener changed: What|Removed |Added Priority|P3 |P2
[Bug c++/92752] [9/10/11/12 Regression] Bogus "ignored qualifiers" warning on const-qualified pointer-to-member-function objects
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92752 Patrick Palka changed: What|Removed |Added Known to fail||10.1.0, 11.1.0, 8.4.0, ||9.3.0 Last reconfirmed||2021-06-18 Known to work||7.5.0 Summary|Bogus "ignored qualifiers" |[9/10/11/12 Regression] |warning on const-qualified |Bogus "ignored qualifiers" |pointer-to-member-function |warning on const-qualified |objects |pointer-to-member-function ||objects Ever confirmed|0 |1 CC||ppalka at gcc dot gnu.org Target Milestone|--- |9.5 Status|UNCONFIRMED |NEW --- Comment #1 from Patrick Palka --- Confirmed. We started to emit the bogus warning after r8-901.