aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJason Merrill <jason@gcc.gnu.org>2000-05-02 01:25:27 -0400
committerJason Merrill <jason@gcc.gnu.org>2000-05-02 01:25:27 -0400
commit3b54e10b04fd2f211f1dc0b384f6de8c235971d4 (patch)
tree7e3b286e1bf42a755cbb908ba317cb239edd58ba /gcc
parent8fd05cb0e70cfd8325a6af95bc3e724fa59d99a3 (diff)
downloadgcc-3b54e10b04fd2f211f1dc0b384f6de8c235971d4.zip
gcc-3b54e10b04fd2f211f1dc0b384f6de8c235971d4.tar.gz
gcc-3b54e10b04fd2f211f1dc0b384f6de8c235971d4.tar.bz2
* tree.c (walk_tree): Set lineno.
From-SVN: r33604
Diffstat (limited to 'gcc')
-rw-r--r--gcc/cp/ChangeLog8
-rw-r--r--gcc/cp/tree.c5
2 files changed, 11 insertions, 2 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index af9d5af..1e96c5c 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,7 @@
+2000-05-01 Jason Merrill <jason@casey.cygnus.com>
+
+ * tree.c (walk_tree): Set lineno.
+
2000-05-01 Mark Mitchell <mark@codesourcery.com>
* exception.cc: Update license notice.
@@ -123,9 +127,9 @@
2000-04-24 Gabriel Dos Reis <gdr@codesourcery.com>
* call.c (standard_conversion): Accept conversion between
- COMPLEX_TYPEs
+ COMPLEX_TYPEs.
- * cvt.c (ocp_convert): Handle conversion to COMPLEX_TYPE
+ * cvt.c (ocp_convert): Handle conversion to COMPLEX_TYPE.
2000-04-24 Zack Weinberg <zack@wolery.cumb.org>
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.