[LLVMbugs] [Bug 7384] New: "using Base::template_mf" doesn't increase access of template_mf if template_mf is called with explicit template parameters
bugzilla-daemon at llvm.org
bugzilla-daemon at llvm.org
Tue Jun 15 11:03:42 PDT 2010
http://llvm.org/bugs/show_bug.cgi?id=7384
Summary: "using Base::template_mf" doesn't increase access of
template_mf if template_mf is called with explicit
template parameters
Product: clang
Version: trunk
Platform: PC
OS/Version: All
Status: NEW
Severity: normal
Priority: P
Component: C++
AssignedTo: unassignedclangbugs at nondot.org
ReportedBy: jyasskin at google.com
CC: llvmbugs at cs.uiuc.edu, dgregor at apple.com
$ cat test2.cc
class Base {
protected:
template<typename T> void Foo(T);
};
struct Derived : Base {
using Base::Foo;
};
void foo() {
Derived d;
d.Foo ARGS(3);
}
$ ./clang++ -fsyntax-only test2.cc -DARGS=
$ ./clang++ -fsyntax-only test2.cc -DARGS="<int>"
test2.cc:12:7: error: 'Foo' is a protected member of 'Base'
d.Foo ARGS(3);
~~^~~~~~~~
test2.cc:3:31: note: declared protected here
template<typename T> void Foo(T);
^
1 error generated.
The call to d.Foo() checks access through the using declaration when it's
called with deduced template arguments, but not when it's called with explicit
ones.
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list