diff options
| author | Fariborz Jahanian <fjahanian@apple.com> | 2012-07-27 21:34:23 +0000 |
|---|---|---|
| committer | Fariborz Jahanian <fjahanian@apple.com> | 2012-07-27 21:34:23 +0000 |
| commit | 84c97cafd063882b956ecc4b6743cbe185ef2ddc (patch) | |
| tree | 0c08814374b3f829f96561531895e86b4912fe6d /clang/lib/Sema | |
| parent | 249716e8aef5ac234a9a29f3ed3d0a931884192e (diff) | |
| download | bcm5719-llvm-84c97cafd063882b956ecc4b6743cbe185ef2ddc.tar.gz bcm5719-llvm-84c97cafd063882b956ecc4b6743cbe185ef2ddc.zip | |
revert r160839 for now.
llvm-svn: 160895
Diffstat (limited to 'clang/lib/Sema')
| -rw-r--r-- | clang/lib/Sema/SemaExprObjC.cpp | 39 |
1 files changed, 27 insertions, 12 deletions
diff --git a/clang/lib/Sema/SemaExprObjC.cpp b/clang/lib/Sema/SemaExprObjC.cpp index 31dfae90552..bd7f25f6d12 100644 --- a/clang/lib/Sema/SemaExprObjC.cpp +++ b/clang/lib/Sema/SemaExprObjC.cpp @@ -2856,12 +2856,19 @@ diagnoseObjCARCConversion(Sema &S, SourceRange castRange, << castRange << castExpr->getSourceRange(); bool br = S.isKnownName("CFBridgingRelease"); - DiagnosticBuilder DiagB = S.Diag(br ? castExpr->getExprLoc() : noteLoc, - diag::note_arc_bridge_transfer) - << castExprType << br; - addFixitForObjCARCConversion(S, DiagB, CCK, afterLParen, - castType, castExpr, "__bridge_transfer ", - br ? "CFBridgingRelease" : 0); + { + DiagnosticBuilder DiagB = S.Diag(noteLoc, diag::note_arc_bridge); + addFixitForObjCARCConversion(S, DiagB, CCK, afterLParen, + castType, castExpr, "__bridge ", 0); + } + { + DiagnosticBuilder DiagB = S.Diag(br ? castExpr->getExprLoc() : noteLoc, + diag::note_arc_bridge_transfer) + << castExprType << br; + addFixitForObjCARCConversion(S, DiagB, CCK, afterLParen, + castType, castExpr, "__bridge_transfer ", + br ? "CFBridgingRelease" : 0); + } return; } @@ -2877,12 +2884,20 @@ diagnoseObjCARCConversion(Sema &S, SourceRange castRange, << castType << castRange << castExpr->getSourceRange(); - DiagnosticBuilder DiagB = S.Diag(br ? castExpr->getExprLoc() : noteLoc, - diag::note_arc_bridge_retained) - << castType << br; - addFixitForObjCARCConversion(S, DiagB, CCK, afterLParen, - castType, castExpr, "__bridge_retained ", - br ? "CFBridgingRetain" : 0); + + { + DiagnosticBuilder DiagB = S.Diag(noteLoc, diag::note_arc_bridge); + addFixitForObjCARCConversion(S, DiagB, CCK, afterLParen, + castType, castExpr, "__bridge ", 0); + } + { + DiagnosticBuilder DiagB = S.Diag(br ? castExpr->getExprLoc() : noteLoc, + diag::note_arc_bridge_retained) + << castType << br; + addFixitForObjCARCConversion(S, DiagB, CCK, afterLParen, + castType, castExpr, "__bridge_retained ", + br ? "CFBridgingRetain" : 0); + } return; } |

