[Lldb-commits] [lldb] r253113 - Fixes for uniformity in type clear and delete commands

Enrico Granata via lldb-commits lldb-commits at lists.llvm.org
Fri Nov 13 17:09:08 PST 2015


Author: enrico
Date: Fri Nov 13 19:09:07 2015
New Revision: 253113

URL: http://llvm.org/viewvc/llvm-project?rev=253113&view=rev
Log:
Fixes for uniformity in type clear and delete commands

Modified:
    lldb/trunk/source/Commands/CommandObjectType.cpp

Modified: lldb/trunk/source/Commands/CommandObjectType.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Commands/CommandObjectType.cpp?rev=253113&r1=253112&r2=253113&view=diff
==============================================================================
--- lldb/trunk/source/Commands/CommandObjectType.cpp (original)
+++ lldb/trunk/source/Commands/CommandObjectType.cpp Fri Nov 13 19:09:07 2015
@@ -1160,10 +1160,8 @@ private:
     PerCategoryCallback(void* param,
                         const lldb::TypeCategoryImplSP& cate)
     {
-        cate->GetTypeFormatsContainer()->Clear();
-        cate->GetRegexTypeFormatsContainer()->Clear();
+        cate->Clear(eFormatCategoryItemValue | eFormatCategoryItemRegexValue);
         return true;
-        
     }
     
 public:
@@ -3581,10 +3579,11 @@ private:
     
     static bool
     PerCategoryCallback(void* param,
-                        const lldb::TypeCategoryImplSP& cate)
+                        const lldb::TypeCategoryImplSP& category_sp)
     {
         ConstString *name = (ConstString*)param;
-        return cate->Delete(*name, eFormatCategoryItemFilter | eFormatCategoryItemRegexFilter);
+        category_sp->Delete(*name, eFormatCategoryItemFilter | eFormatCategoryItemRegexFilter);
+        return true;
     }
     
 public:
@@ -3761,10 +3760,11 @@ private:
     
     static bool
     PerCategoryCallback(void* param,
-                        const lldb::TypeCategoryImplSP& cate)
+                        const lldb::TypeCategoryImplSP& category_sp)
     {
-        ConstString* name = (ConstString*)param;
-        return cate->Delete(*name, eFormatCategoryItemSynth | eFormatCategoryItemRegexSynth);
+        ConstString *name = (ConstString*)param;
+        category_sp->Delete(*name, eFormatCategoryItemSynth | eFormatCategoryItemRegexSynth);
+        return true;
     }
     
 public:




More information about the lldb-commits mailing list