[PATCH] D15624: Add iOS/watchOS/tvOS support for ASan (clang part)

Alexey Samsonov via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 21 10:25:36 PST 2016


samsonov added a comment.

Thanks.


================
Comment at: lib/Driver/ToolChains.cpp:322
@@ -321,1 +321,3 @@
 
+StringRef Darwin::getOSLibraryNameSuffix() const {
+  if (isTargetMacOS())
----------------
Fun fact: if TargetPlatform is `TvOSSimulator`, this function will return `iossim` because `isTargetIOSSimulator` will return true.
I suggest to just switch on the value of `TargetPlatform` instead of using these helpers.

================
Comment at: lib/Driver/ToolChains.cpp:330
@@ +329,3 @@
+  if (isTargetIOSSimulator())
+    return "iossim";
+  if (isTargetIPhoneOS())
----------------
Also, is it possible to add a test case for this?


http://reviews.llvm.org/D15624





More information about the cfe-commits mailing list