23 std::string modified_pattern = pattern;
25 modified_pattern += R
"(:\(.*\).*)"; 28 modified_pattern =
"java::" + modified_pattern;
30 return std::regex{modified_pattern};
40 const size_t descriptor_index = pattern.rfind(
':');
41 if(descriptor_index == std::string::npos)
44 const std::string java_prefix =
"java::";
45 return descriptor_index == java_prefix.length() - 1 &&
56 std::function<std::vector<irep_idt>(
const symbol_tablet &symbol_table)>
62 std::vector<irep_idt> matched_methods;
63 for(
const auto &symbol : symbol_table.symbols)
66 symbol.second.is_function() &&
67 std::regex_match(
id2string(symbol.first), regex))
69 matched_methods.push_back(symbol.first);
72 return matched_methods;
const std::string & id2string(const irep_idt &d)
Process a pattern to use as a regex for selecting extra entry points for ci_lazy_methodst.
bool does_pattern_miss_descriptor(const std::string &pattern)
Identify if a parameter includes a part that will match a descriptor.
bool has_prefix(const std::string &s, const std::string &prefix)
std::function< std::vector< irep_idt >const symbol_tablet &symbol_table)> build_load_method_by_regex(const std::string &pattern)
Create a lambda that returns the symbols that the given pattern should be loaded.If the pattern doesn...
static std::regex build_regex_from_pattern(const std::string &pattern)
For a given user provided pattern, return a regex, having dealt with the cases where the user has not...