This revision was automatically updated to reflect the committed changes.
Closed by commit rL345278: Get rid of casts. (NFC) (authored by adrian, 
committed by ).
Herald added a subscriber: llvm-commits.

Changed prior to commit:
  https://reviews.llvm.org/D53709?vs=171117&id=171119#toc

Repository:
  rL LLVM

https://reviews.llvm.org/D53709

Files:
  lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.cpp
  lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.h


Index: lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.h
===================================================================
--- lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.h
+++ lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.h
@@ -85,7 +85,7 @@
   static std::tuple<llvm::VersionTuple, llvm::StringRef>
   ParseVersionBuildDir(llvm::StringRef str);
 
-  enum class SDKType {
+  enum SDKType : unsigned {
     MacOSX = 0,
     iPhoneSimulator,
     iPhoneOS,
Index: lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.cpp
===================================================================
--- lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.cpp
+++ lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.cpp
@@ -1402,10 +1402,10 @@
   if (last_path_component) {
     const llvm::StringRef sdk_name = last_path_component.GetStringRef();
 
-    if (!sdk_name.startswith(sdk_strings[(int)desired_type]))
+    if (!sdk_name.startswith(sdk_strings[desired_type]))
       return false;
     auto version_part =
-        sdk_name.drop_front(strlen(sdk_strings[(int)desired_type]));
+        sdk_name.drop_front(strlen(sdk_strings[desired_type]));
     version_part.consume_back(".sdk");
 
     llvm::VersionTuple version;


Index: lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.h
===================================================================
--- lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.h
+++ lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.h
@@ -85,7 +85,7 @@
   static std::tuple<llvm::VersionTuple, llvm::StringRef>
   ParseVersionBuildDir(llvm::StringRef str);
 
-  enum class SDKType {
+  enum SDKType : unsigned {
     MacOSX = 0,
     iPhoneSimulator,
     iPhoneOS,
Index: lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.cpp
===================================================================
--- lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.cpp
+++ lldb/trunk/source/Plugins/Platform/MacOSX/PlatformDarwin.cpp
@@ -1402,10 +1402,10 @@
   if (last_path_component) {
     const llvm::StringRef sdk_name = last_path_component.GetStringRef();
 
-    if (!sdk_name.startswith(sdk_strings[(int)desired_type]))
+    if (!sdk_name.startswith(sdk_strings[desired_type]))
       return false;
     auto version_part =
-        sdk_name.drop_front(strlen(sdk_strings[(int)desired_type]));
+        sdk_name.drop_front(strlen(sdk_strings[desired_type]));
     version_part.consume_back(".sdk");
 
     llvm::VersionTuple version;
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to