From 95eae4235d4cfa5cee67ab6c4e686baf8a57e9e5 Mon Sep 17 00:00:00 2001 From: Zachary Turner Date: Wed, 21 Sep 2016 16:01:28 +0000 Subject: Make lldb::Regex use StringRef. This updates getters and setters to use StringRef instead of const char *. I tested the build on Linux, Windows, and OSX and saw no build or test failures. I cannot test any BSD or Android variants, however I expect the required changes to be minimal or non-existant. llvm-svn: 282079 --- lldb/source/Commands/CommandObjectFrame.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'lldb/source/Commands/CommandObjectFrame.cpp') diff --git a/lldb/source/Commands/CommandObjectFrame.cpp b/lldb/source/Commands/CommandObjectFrame.cpp index 05b16bc31f2b..0c28bd0c2c42 100644 --- a/lldb/source/Commands/CommandObjectFrame.cpp +++ b/lldb/source/Commands/CommandObjectFrame.cpp @@ -547,8 +547,9 @@ protected: ++idx) { if (m_option_variable.use_regex) { const size_t regex_start_index = regex_var_list.GetSize(); - RegularExpression regex(name_cstr); - if (regex.Compile(name_cstr)) { + llvm::StringRef name_str(name_cstr); + RegularExpression regex(name_str); + if (regex.Compile(name_str)) { size_t num_matches = 0; const size_t num_new_regex_vars = variable_list->AppendVariablesIfUnique(regex, regex_var_list, -- cgit v1.2.3