diff options
author | John McCall <rjmccall@apple.com> | 2010-02-01 03:16:54 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2010-02-01 03:16:54 +0000 |
commit | 760af170ffa2b384c89dc82da23dc01a2d8d9991 (patch) | |
tree | 0e5452fb2ebd2ef24297e252bb0bef66be5ac98c /clang/lib/Sema/SemaInit.h | |
parent | ed8ca56eeb21bae23e832c05905d3a2ce5016e6f (diff) | |
download | bcm5719-llvm-760af170ffa2b384c89dc82da23dc01a2d8d9991.tar.gz bcm5719-llvm-760af170ffa2b384c89dc82da23dc01a2d8d9991.zip |
Access checking for implicit user-defined conversions.
llvm-svn: 94971
Diffstat (limited to 'clang/lib/Sema/SemaInit.h')
-rw-r--r-- | clang/lib/Sema/SemaInit.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/clang/lib/Sema/SemaInit.h b/clang/lib/Sema/SemaInit.h index 001ba91d546..2b49df28fe8 100644 --- a/clang/lib/Sema/SemaInit.h +++ b/clang/lib/Sema/SemaInit.h @@ -15,6 +15,7 @@ #include "SemaOverload.h" #include "clang/AST/Type.h" +#include "clang/AST/UnresolvedSet.h" #include "clang/Parse/Action.h" #include "clang/Basic/SourceLocation.h" #include "llvm/ADT/PointerIntPair.h" @@ -449,7 +450,11 @@ public: /// \brief When Kind == SK_ResolvedOverloadedFunction or Kind == /// SK_UserConversion, the function that the expression should be /// resolved to or the conversion function to call, respectively. - FunctionDecl *Function; + /// + /// Always a FunctionDecl. + /// For conversion decls, the naming class is the source type. + /// For construct decls, the naming class is the target type. + DeclAccessPair Function; /// \brief When Kind = SK_ConversionSequence, the implicit conversion /// sequence @@ -616,7 +621,9 @@ public: /// \brief Add a new step invoking a conversion function, which is either /// a constructor or a conversion function. - void AddUserConversionStep(FunctionDecl *Function, QualType T); + void AddUserConversionStep(FunctionDecl *Function, + AccessSpecifier Access, + QualType T); /// \brief Add a new step that performs a qualification conversion to the /// given type. @@ -631,6 +638,7 @@ public: /// \brief Add a constructor-initialization step. void AddConstructorInitializationStep(CXXConstructorDecl *Constructor, + AccessSpecifier Access, QualType T); /// \brief Add a zero-initialization step. |