diff options
author | John McCall <rjmccall@apple.com> | 2011-02-01 00:10:29 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2011-02-01 00:10:29 +0000 |
commit | 4fff8f6cff1c8ec7c9d4b294c6ec19b7be120249 (patch) | |
tree | 86c45a0cbe041171dfe99c952af12e8c2bb9163f /clang/lib/Sema/Sema.cpp | |
parent | c1dfd93e1e7bfd230fa3cbc03fcca7cf65957403 (diff) | |
download | bcm5719-llvm-4fff8f6cff1c8ec7c9d4b294c6ec19b7be120249.tar.gz bcm5719-llvm-4fff8f6cff1c8ec7c9d4b294c6ec19b7be120249.zip |
Perform the bad-address-space conversions check as part of
CheckPointerTypesForAssignment.
llvm-svn: 124632
Diffstat (limited to 'clang/lib/Sema/Sema.cpp')
-rw-r--r-- | clang/lib/Sema/Sema.cpp | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/clang/lib/Sema/Sema.cpp b/clang/lib/Sema/Sema.cpp index 1fd12d3b7a9..eda88881a40 100644 --- a/clang/lib/Sema/Sema.cpp +++ b/clang/lib/Sema/Sema.cpp @@ -206,15 +206,6 @@ void Sema::ImpCastExprToType(Expr *&Expr, QualType Ty, if (ExprTy == TypeTy) return; - if (Expr->getType()->isPointerType() && Ty->isPointerType()) { - QualType ExprBaseType = cast<PointerType>(ExprTy)->getPointeeType(); - QualType BaseType = cast<PointerType>(TypeTy)->getPointeeType(); - if (ExprBaseType.getAddressSpace() != BaseType.getAddressSpace()) { - Diag(Expr->getExprLoc(), diag::err_implicit_pointer_address_space_cast) - << Expr->getSourceRange(); - } - } - // If this is a derived-to-base cast to a through a virtual base, we // need a vtable. if (Kind == CK_DerivedToBase && |