Added an "rb" alias that sets breakpoints by
authorSean Callanan <scallanan@apple.com>
Mon, 21 May 2012 18:25:19 +0000 (18:25 +0000)
committerSean Callanan <scallanan@apple.com>
Mon, 21 May 2012 18:25:19 +0000 (18:25 +0000)
regular expression.

llvm-svn: 157202

lldb/source/Interpreter/CommandInterpreter.cpp

index 074ef53..3e6597b 100644 (file)
@@ -256,6 +256,15 @@ CommandInterpreter::Initialize ()
     {
         AddAlias ("add-dsym", cmd_obj_sp);
     }
+    
+    cmd_obj_sp = GetCommandSPExact ("breakpoint set", false);
+    if (cmd_obj_sp)
+    {
+        alias_arguments_vector_sp.reset (new OptionArgVector);
+        ProcessAliasOptionsArgs (cmd_obj_sp, "--func-regex %1", alias_arguments_vector_sp);
+        AddAlias ("rb", cmd_obj_sp);
+        AddOrReplaceAliasOptions("rb", alias_arguments_vector_sp);
+    }
 }
 
 const char *