diff options
Diffstat (limited to 'gcc/cp/tree.c')
| -rw-r--r-- | gcc/cp/tree.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c index 47209b2..c3bdb1d 100644 --- a/gcc/cp/tree.c +++ b/gcc/cp/tree.c @@ -1245,6 +1245,11 @@ walk_tree (tp, func, data) { int i, len; + /* Set lineno here so we get the right instantiation context + if we call instantiate_decl from inlinable_function_p. */ + if (statement_code_p (code) && !STMT_LINENO_FOR_FN_P (*tp)) + lineno = STMT_LINENO (*tp); + /* Walk over all the sub-trees of this operand. */ len = first_rtl_op (code); /* TARGET_EXPRs are peculiar: operands 1 and 3 can be the same. |
