John McCall
5b0829a321
Improve access control diagnostics. Perform access control on member-pointer
...
conversions. Fix an access-control bug where privileges were not considered
at intermediate points along the inheritance path. Prepare for friends.
llvm-svn: 95775
2010-02-10 09:31:12 +00:00
John McCall
03c4848bf4
Mark dtors for parameter variables and eliminate some redundant type munging.
...
llvm-svn: 95079
2010-02-02 09:10:11 +00:00
John McCall
6781b05a92
Access control for implicit destructor calls. Diagnostic could be orders of
...
magnitude clearer.
llvm-svn: 95078
2010-02-02 08:45:54 +00:00
John McCall
760af170ff
Access checking for implicit user-defined conversions.
...
llvm-svn: 94971
2010-02-01 03:16:54 +00:00
John McCall
b3a4400554
Access checking for overloaded operators.
...
llvm-svn: 94725
2010-01-28 01:42:12 +00:00
John McCall
86121519ca
Implement access-check delays for out-of-line member definitions
...
using the same framework we use for deprecation warnings.
llvm-svn: 94659
2010-01-27 03:50:35 +00:00
John McCall
58cc69d4c1
Implement access control for overloaded functions. Suppress access control
...
diagnostics in "early" lookups, such as during typename checks and when building
unresolved lookup expressions.
llvm-svn: 94647
2010-01-27 01:50:18 +00:00
John McCall
553c0796ee
Implement elementary access control.
...
llvm-svn: 94268
2010-01-23 00:46:32 +00:00
John McCall
0a4bb26ed0
Set a member's access specifier even if it doesn't match the previous specifier.
...
Prevents an assert on successive redeclarations.
Fixed PR5573.
llvm-svn: 91956
2009-12-23 00:37:40 +00:00
Douglas Gregor
36d1b14dde
Refactor the code that walks a C++ inheritance hierarchy, searching
...
for bases, members, overridden virtual methods, etc. The operations
isDerivedFrom and lookupInBases are now provided by CXXRecordDecl,
rather than by Sema, so that CodeGen and other clients can use them
directly.
llvm-svn: 83396
2009-10-06 17:59:45 +00:00
Mike Stump
11289f4280
Remove tabs, and whitespace cleanups.
...
llvm-svn: 81346
2009-09-09 15:08:12 +00:00
Sebastian Redl
e644e19671
Enhance testing of overriding exception specs for inaccessible base exceptions.
...
llvm-svn: 76317
2009-07-18 14:32:15 +00:00
Anders Carlsson
49d216db15
Add a new, more advanced CheckDerivedToBaseConversion that takes custom diagnostic IDs.
...
llvm-svn: 71720
2009-05-13 21:11:42 +00:00
Anders Carlsson
5879fbd933
Disable access control by default. It can be enabled with the -faccess-control option. When we have better support for it, we can enable it by default again.
...
llvm-svn: 71706
2009-05-13 19:49:53 +00:00
Anders Carlsson
72f307a26e
Revert Sebastian's rvalue patch (r67870) since it caused test failures in
...
SemaCXX//overload-member-call.cpp
SemaCXX//overloaded-operator.cpp
SemaTemplate//instantiate-method.cpp
llvm-svn: 67912
2009-03-28 04:17:27 +00:00
Anders Carlsson
0cb4cc106c
Implement access checking for protected base classes.
...
llvm-svn: 67887
2009-03-28 01:09:05 +00:00
Anders Carlsson
af06b977f9
It is OK to cast to a private base class if the current member belongs to the class that the private base class is a base of:
...
class A {};
class B : private A {
void f(B *b) { A* a = b; }
};
llvm-svn: 67860
2009-03-27 19:01:12 +00:00
Anders Carlsson
733d77f1b4
Implement checking for base class access. Right now it's overly conservative but that will change. (Also, protected isn't implemented right now).
...
llvm-svn: 67827
2009-03-27 06:03:27 +00:00
Anders Carlsson
4742a9c19a
Add a stubbed out CheckBaseClassAccess method.
...
llvm-svn: 67821
2009-03-27 05:05:05 +00:00
Anders Carlsson
17941120d6
Move Sema::SetMemberAccessSpecifier to SemaAccess.cpp
...
llvm-svn: 67820
2009-03-27 04:54:36 +00:00
Anders Carlsson
8ed6f3645b
Add SemaAccess.cpp
...
llvm-svn: 67819
2009-03-27 04:43:36 +00:00