public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug c++/16617] New: Fail to do access checking correctly for non-dependent qualified-id @ 2004-07-18 13:52 lerdsuwa at gcc dot gnu dot org 2004-07-18 19:46 ` [Bug c++/16617] " giovannibajo at libero dot it ` (6 more replies) 0 siblings, 7 replies; 12+ messages in thread From: lerdsuwa at gcc dot gnu dot org @ 2004-07-18 13:52 UTC (permalink / raw) To: gcc-bugs This is a spin out of a problem mentioned in PR13092. The following testcase shouldn't compile because only fr<int> is friend of class D. But we are accessing protected members from fr<char>. GCC 3.4, 3.5 fail to diagnose it. Earlier GCC don't handle this properly (checking access while parsing the template fr<T> which is too early.) So it's not a regression. // Two-phase name lookup for address of member: // Protected member access class B { protected: int i; // { dg-error "protected" } }; template <class T> void fr (); class D2 : public B { friend void fr<int> (); }; template<int B::*> struct X {}; template <class T> void fr () { X<&B::i> x1; // { dg-error "context" } X<&D2::i> x2; // { dg-error "context" } } template void fr<char>(); // { dg-error "instantiated" } -- Summary: Fail to do access checking correctly for non-dependent qualified-id Product: gcc Version: 3.5.0 Status: UNCONFIRMED Keywords: accepts-invalid Severity: normal Priority: P2 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: lerdsuwa at gcc dot gnu dot org CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id 2004-07-18 13:52 [Bug c++/16617] New: Fail to do access checking correctly for non-dependent qualified-id lerdsuwa at gcc dot gnu dot org @ 2004-07-18 19:46 ` giovannibajo at libero dot it 2004-07-28 13:48 ` bangerth at dealii dot org ` (5 subsequent siblings) 6 siblings, 0 replies; 12+ messages in thread From: giovannibajo at libero dot it @ 2004-07-18 19:46 UTC (permalink / raw) To: gcc-bugs -- What |Removed |Added ---------------------------------------------------------------------------- CC| |giovannibajo at libero dot | |it http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id 2004-07-18 13:52 [Bug c++/16617] New: Fail to do access checking correctly for non-dependent qualified-id lerdsuwa at gcc dot gnu dot org 2004-07-18 19:46 ` [Bug c++/16617] " giovannibajo at libero dot it @ 2004-07-28 13:48 ` bangerth at dealii dot org 2004-12-12 12:42 ` lerdsuwa at gcc dot gnu dot org ` (4 subsequent siblings) 6 siblings, 0 replies; 12+ messages in thread From: bangerth at dealii dot org @ 2004-07-28 13:48 UTC (permalink / raw) To: gcc-bugs ------- Additional Comments From bangerth at dealii dot org 2004-07-28 13:48 ------- Confirmed. W. -- What |Removed |Added ---------------------------------------------------------------------------- Status|UNCONFIRMED |NEW Ever Confirmed| |1 Last reconfirmed|0000-00-00 00:00:00 |2004-07-28 13:48:57 date| | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id 2004-07-18 13:52 [Bug c++/16617] New: Fail to do access checking correctly for non-dependent qualified-id lerdsuwa at gcc dot gnu dot org 2004-07-18 19:46 ` [Bug c++/16617] " giovannibajo at libero dot it 2004-07-28 13:48 ` bangerth at dealii dot org @ 2004-12-12 12:42 ` lerdsuwa at gcc dot gnu dot org 2005-01-12 10:50 ` lerdsuwa at gcc dot gnu dot org ` (3 subsequent siblings) 6 siblings, 0 replies; 12+ messages in thread From: lerdsuwa at gcc dot gnu dot org @ 2004-12-12 12:42 UTC (permalink / raw) To: gcc-bugs ------- Additional Comments From lerdsuwa at gcc dot gnu dot org 2004-12-12 12:42 ------- Got it. The target for this fix is GCC 4.1. -- What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|unassigned at gcc dot gnu |lerdsuwa at gcc dot gnu dot |dot org |org Status|NEW |ASSIGNED http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id 2004-07-18 13:52 [Bug c++/16617] New: Fail to do access checking correctly for non-dependent qualified-id lerdsuwa at gcc dot gnu dot org ` (2 preceding siblings ...) 2004-12-12 12:42 ` lerdsuwa at gcc dot gnu dot org @ 2005-01-12 10:50 ` lerdsuwa at gcc dot gnu dot org 2005-04-23 15:30 ` lerdsuwa at gcc dot gnu dot org ` (2 subsequent siblings) 6 siblings, 0 replies; 12+ messages in thread From: lerdsuwa at gcc dot gnu dot org @ 2005-01-12 10:50 UTC (permalink / raw) To: gcc-bugs ------- Additional Comments From lerdsuwa at gcc dot gnu dot org 2005-01-12 10:50 ------- May be fixed together with PR19311. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id 2004-07-18 13:52 [Bug c++/16617] New: Fail to do access checking correctly for non-dependent qualified-id lerdsuwa at gcc dot gnu dot org ` (3 preceding siblings ...) 2005-01-12 10:50 ` lerdsuwa at gcc dot gnu dot org @ 2005-04-23 15:30 ` lerdsuwa at gcc dot gnu dot org 2005-05-19 17:09 ` lerdsuwa at gcc dot gnu dot org 2005-06-07 14:59 ` lerdsuwa at gcc dot gnu dot org 6 siblings, 0 replies; 12+ messages in thread From: lerdsuwa at gcc dot gnu dot org @ 2005-04-23 15:30 UTC (permalink / raw) To: gcc-bugs ------- Additional Comments From lerdsuwa at gcc dot gnu dot org 2005-04-23 15:30 ------- This is a stage 2 project. Likely to be fixed in a month or two. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id 2004-07-18 13:52 [Bug c++/16617] New: Fail to do access checking correctly for non-dependent qualified-id lerdsuwa at gcc dot gnu dot org ` (4 preceding siblings ...) 2005-04-23 15:30 ` lerdsuwa at gcc dot gnu dot org @ 2005-05-19 17:09 ` lerdsuwa at gcc dot gnu dot org 2005-06-07 14:59 ` lerdsuwa at gcc dot gnu dot org 6 siblings, 0 replies; 12+ messages in thread From: lerdsuwa at gcc dot gnu dot org @ 2005-05-19 17:09 UTC (permalink / raw) To: gcc-bugs ------- Additional Comments From lerdsuwa at gcc dot gnu dot org 2005-05-19 17:09 ------- Patch using new approach for 4.1: http://gcc.gnu.org/ml/gcc-patches/2005-05/msg01992.html (Note this is part 4 in a series, earlier parts are also required) -- What |Removed |Added ---------------------------------------------------------------------------- URL| |http://gcc.gnu.org/ml/gcc- | |patches/2005- | |05/msg01992.html Keywords| |patch http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id 2004-07-18 13:52 [Bug c++/16617] New: Fail to do access checking correctly for non-dependent qualified-id lerdsuwa at gcc dot gnu dot org ` (5 preceding siblings ...) 2005-05-19 17:09 ` lerdsuwa at gcc dot gnu dot org @ 2005-06-07 14:59 ` lerdsuwa at gcc dot gnu dot org 6 siblings, 0 replies; 12+ messages in thread From: lerdsuwa at gcc dot gnu dot org @ 2005-06-07 14:59 UTC (permalink / raw) To: gcc-bugs ------- Additional Comments From lerdsuwa at gcc dot gnu dot org 2005-06-07 14:58 ------- Patch withdrawn due to overlooking default function argument and default template argument. No nice solution is found yet. -- What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|lerdsuwa at gcc dot gnu dot |unassigned at gcc dot gnu |org |dot org Status|ASSIGNED |NEW Keywords|patch | http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
[parent not found: <bug-16617-16@http.gcc.gnu.org/bugzilla/>]
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id [not found] <bug-16617-16@http.gcc.gnu.org/bugzilla/> @ 2009-04-29 7:05 ` pinskia at gcc dot gnu dot org 2009-04-29 7:05 ` pinskia at gcc dot gnu dot org 1 sibling, 0 replies; 12+ messages in thread From: pinskia at gcc dot gnu dot org @ 2009-04-29 7:05 UTC (permalink / raw) To: gcc-bugs ------- Comment #8 from pinskia at gcc dot gnu dot org 2009-04-29 07:05 ------- *** Bug 24118 has been marked as a duplicate of this bug. *** -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |rguenth at gcc dot gnu dot | |org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id [not found] <bug-16617-16@http.gcc.gnu.org/bugzilla/> 2009-04-29 7:05 ` pinskia at gcc dot gnu dot org @ 2009-04-29 7:05 ` pinskia at gcc dot gnu dot org 1 sibling, 0 replies; 12+ messages in thread From: pinskia at gcc dot gnu dot org @ 2009-04-29 7:05 UTC (permalink / raw) To: gcc-bugs ------- Comment #7 from pinskia at gcc dot gnu dot org 2009-04-29 07:05 ------- *** Bug 33934 has been marked as a duplicate of this bug. *** -- pinskia at gcc dot gnu dot org changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |sutambe at yahoo dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 ^ permalink raw reply [flat|nested] 12+ messages in thread
[parent not found: <bug-16617-4@http.gcc.gnu.org/bugzilla/>]
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id [not found] <bug-16617-4@http.gcc.gnu.org/bugzilla/> @ 2021-04-22 17:41 ` cvs-commit at gcc dot gnu.org 2021-04-22 17:45 ` ppalka at gcc dot gnu.org 1 sibling, 0 replies; 12+ messages in thread From: cvs-commit at gcc dot gnu.org @ 2021-04-22 17:41 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 --- Comment #9 from CVS Commits <cvs-commit at gcc dot gnu.org> --- The master branch has been updated by Patrick Palka <ppalka@gcc.gnu.org>: https://gcc.gnu.org/g:330cc29c06306ebf7bd3b2d37704cc69944923ff commit r12-69-g330cc29c06306ebf7bd3b2d37704cc69944923ff Author: Patrick Palka <ppalka@redhat.com> Date: Thu Apr 22 13:32:40 2021 -0400 c++: Add testcase for already fixed PR [PR16617] We correctly diagnose the invalid access since r11-1350. gcc/testsuite/ChangeLog: PR c++/16617 * g++.dg/template/access36.C: New test. ^ permalink raw reply [flat|nested] 12+ messages in thread
* [Bug c++/16617] Fail to do access checking correctly for non-dependent qualified-id [not found] <bug-16617-4@http.gcc.gnu.org/bugzilla/> 2021-04-22 17:41 ` cvs-commit at gcc dot gnu.org @ 2021-04-22 17:45 ` ppalka at gcc dot gnu.org 1 sibling, 0 replies; 12+ messages in thread From: ppalka at gcc dot gnu.org @ 2021-04-22 17:45 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=16617 Patrick Palka <ppalka at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED CC| |ppalka at gcc dot gnu.org Target Milestone|--- |11.0 Resolution|--- |FIXED --- Comment #10 from Patrick Palka <ppalka at gcc dot gnu.org> --- Fixed for GCC 11 by the patch for PR41437. ^ permalink raw reply [flat|nested] 12+ messages in thread
end of thread, other threads:[~2021-04-22 17:45 UTC | newest] Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2004-07-18 13:52 [Bug c++/16617] New: Fail to do access checking correctly for non-dependent qualified-id lerdsuwa at gcc dot gnu dot org 2004-07-18 19:46 ` [Bug c++/16617] " giovannibajo at libero dot it 2004-07-28 13:48 ` bangerth at dealii dot org 2004-12-12 12:42 ` lerdsuwa at gcc dot gnu dot org 2005-01-12 10:50 ` lerdsuwa at gcc dot gnu dot org 2005-04-23 15:30 ` lerdsuwa at gcc dot gnu dot org 2005-05-19 17:09 ` lerdsuwa at gcc dot gnu dot org 2005-06-07 14:59 ` lerdsuwa at gcc dot gnu dot org [not found] <bug-16617-16@http.gcc.gnu.org/bugzilla/> 2009-04-29 7:05 ` pinskia at gcc dot gnu dot org 2009-04-29 7:05 ` pinskia at gcc dot gnu dot org [not found] <bug-16617-4@http.gcc.gnu.org/bugzilla/> 2021-04-22 17:41 ` cvs-commit at gcc dot gnu.org 2021-04-22 17:45 ` ppalka at gcc dot gnu.org
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).