diff options
author | Jason Merrill <jason@redhat.com> | 2010-10-27 11:48:26 -0400 |
---|---|---|
committer | Jason Merrill <jason@gcc.gnu.org> | 2010-10-27 11:48:26 -0400 |
commit | 73808ca6a4b67e9e8dea94e36635122b445262b2 (patch) | |
tree | d5c8b9b559b946e96878c1e5eafdf553e2e1b83b /gcc/cp | |
parent | 236fd18cbaf1bde6093024b096627e7cdb488417 (diff) | |
download | gcc-73808ca6a4b67e9e8dea94e36635122b445262b2.zip gcc-73808ca6a4b67e9e8dea94e36635122b445262b2.tar.gz gcc-73808ca6a4b67e9e8dea94e36635122b445262b2.tar.bz2 |
* except.c (build_throw): Set EXPR_LOCATION.
From-SVN: r166008
Diffstat (limited to 'gcc/cp')
-rw-r--r-- | gcc/cp/ChangeLog | 2 | ||||
-rw-r--r-- | gcc/cp/except.c | 5 |
2 files changed, 6 insertions, 1 deletions
diff --git a/gcc/cp/ChangeLog b/gcc/cp/ChangeLog index d0ea05c..35bcd65 100644 --- a/gcc/cp/ChangeLog +++ b/gcc/cp/ChangeLog @@ -1,5 +1,7 @@ 2010-10-27 Jason Merrill <jason@redhat.com> + * except.c (build_throw): Set EXPR_LOCATION. + * tree.c (build_cplus_new): Handle CONSTRUCTOR. * semantics.c (finish_compound_stmt): Avoid creating an diff --git a/gcc/cp/except.c b/gcc/cp/except.c index b917664..cf8a210 100644 --- a/gcc/cp/except.c +++ b/gcc/cp/except.c @@ -648,7 +648,9 @@ build_throw (tree exp) { if (cfun) current_function_returns_abnormally = 1; - return build_min (THROW_EXPR, void_type_node, exp); + exp = build_min (THROW_EXPR, void_type_node, exp); + SET_EXPR_LOCATION (exp, input_location); + return exp; } if (exp == null_node) @@ -834,6 +836,7 @@ build_throw (tree exp) } exp = build1 (THROW_EXPR, void_type_node, exp); + SET_EXPR_LOCATION (exp, input_location); return exp; } |