summaryrefslogtreecommitdiffstats
path: root/clang/test/CXX/class.access
Commit message (Collapse)AuthorAgeFilesLines
...
* Reapply r99596 with a fix: link an instantiated friend function to itsJohn McCall2010-03-261-0/+15
| | | | | | pattern if it has a body. llvm-svn: 99610
* When finishing a function definition, leave the function definition *after*John McCall2010-03-251-0/+12
| | | | | | | doing all the cleanup tasks and checks. This gives us the proper context for checking access to base and member destructors. llvm-svn: 99559
* Fix a very minor oversight in privileges-elevation: we were only consideringJohn McCall2010-03-251-0/+16
| | | | | | | friendship for a derived class if the base class specifier was non-public, and thus not considering friendship for non-public members of public bases. llvm-svn: 99554
* Walk out of enums when determining effective context.John McCall2010-03-241-0/+21
| | | | llvm-svn: 99391
* When elevating access along an inheritance path, initialize the computedJohn McCall2010-03-182-0/+46
| | | | | | | | | | | | | | | | access to the (elevated) access of the accessed declaration, if applicable, rather than plunking that access onto the end after we've calculated the inheritance access. Also, being a friend of a derived class gives you public access to its members (subject to later modification by further inheritance); it does not simply ignore a single location of restricted inheritance. Also, when computing the best unprivileged path to a subobject, preserve the information that the worst path might be AS_none (forbidden) rather than a minimum of AS_private. llvm-svn: 98899
* from code inspection, we were treating placement news with one argument asJohn McCall2010-03-181-0/+17
| | | | | | | | non-placement news when selecting the corresponding operator delete; this is fixed. Access and ambiguity control for calls to operator new and delete. Also AFAICT llvm-svn: 98818
* Redeclaration lookups for parameter names should be flagged as redeclaration ↵John McCall2010-03-181-0/+12
| | | | | | | | lookups so they don't trigger diagnostics like (say) access control. llvm-svn: 98806
* Grant nested classes the access privileges of their enclosing classes.John McCall2010-03-171-0/+33
| | | | llvm-svn: 98710
* Perform access control for the implicit calls to base and member destructorsJohn McCall2010-03-161-8/+9
| | | | | | that occur in constructors (on the unwind path). llvm-svn: 98681
* Access control for implicit calls to copy assignment operators and copyJohn McCall2010-03-161-0/+37
| | | | | | constructors from implicitly-defined members. llvm-svn: 98614
* Perform access control even for the implicit destructor calls from implicitJohn McCall2010-03-161-2/+11
| | | | | | destructor definitions. Remove some code duplication. llvm-svn: 98611
* Perform access control for the implicit base and member destructor callsJohn McCall2010-03-161-4/+22
| | | | | | required when emitting a destructor definition. llvm-svn: 98609
* Remember access paths for visible conversion decls.John McCall2010-03-151-0/+44
| | | | llvm-svn: 98539
* Add an extra test to this test-case.John McCall2010-03-121-1/+7
| | | | llvm-svn: 98322
* Implement basic support for friend types and functions in non-dependentJohn McCall2010-03-121-1/+50
| | | | | | contexts. llvm-svn: 98321
* When pretty-printing tag types, only print the tag if we're in C (andJohn McCall2010-03-101-9/+9
| | | | | | | | | | therefore not creating ElaboratedTypes, which are still pretty-printed with the written tag). Most of these testcase changes were done by script, so don't feel too sorry for my fingers. llvm-svn: 98149
* Fix the lookup of names used in a friend declaration to not attempt toChandler Carruth2010-03-011-0/+62
| | | | | | | re-declare them. This fixes PR6317. Also add the beginnings of an interesting test case for p1 of [class.friend] which also covers PR6317. llvm-svn: 97499
* Improve access control diagnostics. Perform access control on member-pointerJohn McCall2010-02-103-45/+44
| | | | | | | conversions. Fix an access-control bug where privileges were not considered at intermediate points along the inheritance path. Prepare for friends. llvm-svn: 95775
* Access control for implicit destructor calls. Diagnostic could be orders ofJohn McCall2010-02-021-0/+29
| | | | | | magnitude clearer. llvm-svn: 95078
* Access checking for implicit user-defined conversions.John McCall2010-02-011-0/+28
| | | | llvm-svn: 94971
* Access control for surrogate function calls. Required a moderately gross hackJohn McCall2010-01-281-0/+10
| | | | | | to get the access bits set properly in conversion sets. llvm-svn: 94744
* Access control for overloaded call operators. Not for surrogates yet,John McCall2010-01-281-0/+6
| | | | | | | | mostly because we're going to want a better diagnostic for conversions. Also this API needs to go back to sanity. llvm-svn: 94730
* Access checking for overloaded operators.John McCall2010-01-281-0/+36
| | | | llvm-svn: 94725
* Implement access-check delays for out-of-line member definitionsJohn McCall2010-01-271-0/+26
| | | | | | using the same framework we use for deprecation warnings. llvm-svn: 94659
* Implement access control for overloaded functions. Suppress access controlJohn McCall2010-01-271-0/+33
| | | | | | | diagnostics in "early" lookups, such as during typename checks and when building unresolved lookup expressions. llvm-svn: 94647
* Implement elementary access control.John McCall2010-01-231-0/+152
| | | | llvm-svn: 94268
* Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.Daniel Dunbar2009-12-151-1/+1
| | | | | | | | | - This is designed to make it obvious that %clang_cc1 is a "test variable" which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it can be useful to redefine what gets run as 'clang -cc1' (for example, to set a default target). llvm-svn: 91446
* Implement access declarations. Most of the work here is parsing them, whichJohn McCall2009-12-111-0/+199
is difficult because they're so terribly, terribly ambiguous. We implement access declarations in terms of using declarations, which is quite reasonable. However, we should really persist the access/using distinction in the AST and use the appropriate name in diagnostics. This isn't a priority, so I'll just file a PR and hope someone else does it. :) llvm-svn: 91095
OpenPOWER on IntegriCloud