summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/TwoAddressInstructionPass.cpp
diff options
context:
space:
mode:
authorJordan Rose <jordan_rose@apple.com>2012-07-17 17:46:48 +0000
committerJordan Rose <jordan_rose@apple.com>2012-07-17 17:46:48 +0000
commit63ffaa8c18f1caabc6820505ba1ce960252c5188 (patch)
tree53e8fc65bf84b348cf6d573575a0cf6907341059 /llvm/lib/CodeGen/TwoAddressInstructionPass.cpp
parentea70bf71547b9c8d96735707541e55fe117e23b5 (diff)
downloadbcm5719-llvm-63ffaa8c18f1caabc6820505ba1ce960252c5188.tar.gz
bcm5719-llvm-63ffaa8c18f1caabc6820505ba1ce960252c5188.zip
-Wobjc-literal-compare: don't warn when comparing against nil.
Checks against nil often appear as guards in macros, and comparing Objective-C literals to nil has well-defined behavior (if tautological). On OS X, 'nil' has not been typed as 'id' since 10.6 (possibly earlier), so the warning was already not firing, but other runtimes continue to use ((id)0) or some variant. This change accepts comparisons to any null pointer; to keep it simple, it looks through all casts (not just casts to 'id'). PR13276 llvm-svn: 160379
Diffstat (limited to 'llvm/lib/CodeGen/TwoAddressInstructionPass.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud