From: Jason Merrill Date: Thu, 29 Mar 2018 19:38:35 +0000 (-0400) Subject: * pt.c (build_non_dependent_expr): Propagate expr location. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=8de4a6749d16ac2663ee5a071906b8d469ad9049;p=gcc.git * pt.c (build_non_dependent_expr): Propagate expr location. From-SVN: r258963 --- diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index 454866e6e77..cc950e8d74e 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,3 +1,7 @@ +2018-03-29 Jason Merrill + + * pt.c (build_non_dependent_expr): Propagate expr location. + 2018-03-27 Jason Merrill PR c++/85060 - wrong-code with call to base member in template. diff --git a/gcc/cp/pt.c b/gcc/cp/pt.c index 07dad996504..40ddf9ec989 100644 --- a/gcc/cp/pt.c +++ b/gcc/cp/pt.c @@ -25473,7 +25473,8 @@ build_non_dependent_expr (tree expr) gcc_assert (TREE_TYPE (expr) != unknown_type_node); /* Otherwise, build a NON_DEPENDENT_EXPR. */ - return build1 (NON_DEPENDENT_EXPR, TREE_TYPE (expr), expr); + return build1_loc (EXPR_LOCATION (orig_expr), NON_DEPENDENT_EXPR, + TREE_TYPE (expr), expr); } /* ARGS is a vector of expressions as arguments to a function call.