aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Commands/CommandObjectArgs.cpp
diff options
context:
space:
mode:
authorJordan Rose <jordan_rose@apple.com>2012-06-08 21:14:25 +0000
committerJordan Rose <jordan_rose@apple.com>2012-06-08 21:14:25 +0000
commitd49a33e86cd8ca68f35d2d839e65b03b4892f3cf (patch)
tree953c269c8850cb7d82521d331b973bf4b462376d /lldb/source/Commands/CommandObjectArgs.cpp
parentb5a94f45d22e43241c80c4a26994de0c4c28b92b (diff)
downloadllvm-d49a33e86cd8ca68f35d2d839e65b03b4892f3cf.zip
llvm-d49a33e86cd8ca68f35d2d839e65b03b4892f3cf.tar.gz
llvm-d49a33e86cd8ca68f35d2d839e65b03b4892f3cf.tar.bz2
Disallow using ObjC literals in direct comparisons (== and friends).
Objective-C literals conceptually always create new objects, but may be optimized by the compiler or runtime (constant folding, singletons, etc). Comparing addresses of these objects is relying on this optimization behavior, which is really an implementation detail. In the case of == and !=, offer a fixit to a call to -isEqual:, if the method is available. This fixit is directly on the error so that it is automatically applied. Most of the time, this is really a newbie mistake, hence the fixit. llvm-svn: 158230
Diffstat (limited to 'lldb/source/Commands/CommandObjectArgs.cpp')
0 files changed, 0 insertions, 0 deletions