gcc/cp/ChangeLog: * typeck.c (string_conv_p): Strip any location wrapper from "exp". --- gcc/cp/typeck.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/gcc/cp/typeck.c b/gcc/cp/typeck.c index dd3e19d..523e4d3 100644 --- a/gcc/cp/typeck.c +++ b/gcc/cp/typeck.c @@ -2149,6 +2149,8 @@ string_conv_p (const_tree totype, const_tree exp, int warn) && !same_type_p (t, wchar_type_node)) return 0; + STRIP_ANY_LOCATION_WRAPPER (exp); + if (TREE_CODE (exp) == STRING_CST) { /* Make sure that we don't try to convert between char and wide chars. */ -- 1.8.5.3