aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorPer Bothner <pbothner@apple.com>2003-07-25 04:04:30 +0000
committerPer Bothner <bothner@gcc.gnu.org>2003-07-24 21:04:30 -0700
commitb3179b0d5148aabc9635eee8759e8057518cef83 (patch)
tree39fe3125b44ef171cccfa424c5c9d5d41fdff417 /gcc
parentc60ab83164fc267f104fbda12eb30df94a3699fe (diff)
downloadgcc-b3179b0d5148aabc9635eee8759e8057518cef83.zip
gcc-b3179b0d5148aabc9635eee8759e8057518cef83.tar.gz
gcc-b3179b0d5148aabc9635eee8759e8057518cef83.tar.bz2
decl.c (pushdecl_class_level): Don't use push_srcloc/pop_srcloc which causes errors messages to incorrectly...
* decl.c (pushdecl_class_level): Don't use push_srcloc/pop_srcloc which causes errors messages to incorrectly mention included files. From-SVN: r69771
Diffstat (limited to 'gcc')
-rw-r--r--gcc/cp/ChangeLog5
-rw-r--r--gcc/cp/decl.c5
2 files changed, 8 insertions, 2 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog
index a4e454b..7abf46b 100644
--- a/gcc/cp/ChangeLog
+++ b/gcc/cp/ChangeLog
@@ -1,3 +1,8 @@
+2003-07-24 Per Bothner <pbothner@apple.com>
+
+ * decl.c (pushdecl_class_level): Don't use push_srcloc/pop_srcloc
+ which causes errors messages to incorrectly mention included files.
+
2003-07-24 Mark Mitchell <mark@codesourcery.com>
* cp-tree.h (convert_to_base_statically): Declare.
diff --git a/gcc/cp/decl.c b/gcc/cp/decl.c
index 4443d70..cec42f3 100644
--- a/gcc/cp/decl.c
+++ b/gcc/cp/decl.c
@@ -4209,10 +4209,11 @@ pushdecl_class_level (tree x)
for (f = TYPE_FIELDS (TREE_TYPE (x)); f; f = TREE_CHAIN (f))
{
- push_srcloc (DECL_SOURCE_FILE (f), DECL_SOURCE_LINE (f));
+ location_t save_location = input_location;
+ input_location = DECL_SOURCE_LOCATION (f);
if (!pushdecl_class_level (f))
is_valid = false;
- pop_srcloc ();
+ input_location = save_location;
}
}
timevar_pop (TV_NAME_LOOKUP);