HomePhabricator

Fix PR#44620 'readability-redundant-string-cstr quick-fix causes invalid code'

Authored by f00kat on Feb 18 2020, 12:32 PM.

Description

Fix PR#44620 'readability-redundant-string-cstr quick-fix causes invalid code'

static void f2(std::string&&) {}
static void f() {
std::string const s;
f2(s.c_str()); // readability-redundant-string-cstr previously warning
}

Skips the problematic AST pattern in the matcher.

Details

Committed
aaron.ballmanFeb 18 2020, 12:33 PM
Parents
rGfaa889b23587: [Hexagon] clang driver should consider --sysroot option
Branches
Unknown
Tags
Unknown