r282079 converted the regular expression interface to accept
and return StringRefs instead of char pointers. In one case
a null pointer check was converted to an empty string check,
but this was an incorrect conversion because an empty string
is a valid regular expression. Removing this check should
fix the test failures.
llvm-svn: 282090
//---------------------------------------------------------------------
bool RegularExpression::Execute(llvm::StringRef str, Match *match) const {
int err = 1;
- if (!str.empty() && m_comp_err == 0) {
+ if (m_comp_err == 0) {
// Argument to regexec must be null-terminated.
std::string reg_str = str;
if (match) {