A colleague sees a strange warning by clang static analyzer (actually from clang-check).
This code:
#include <regex>
int main() {
std::regex_match("jee", std::regex("lol"));
return 0;
}
produces analyzer warning:
/usr/local/clang+llvm-3.9.0-x86_64-apple-darwin/bin/../include/c++/v1/regex:5724:17: warning: Called C++ object pointer is null s._node->__exec_split(true, s); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 warning generated.
What is going on here?