diff options
author | Aldy Hernandez <aldyh@redhat.com> | 2015-02-21 00:27:05 +0000 |
---|---|---|
committer | Aldy Hernandez <aldyh@gcc.gnu.org> | 2015-02-21 00:27:05 +0000 |
commit | 220d905f7c53b81c4572450f9caf6197b2cc6c02 (patch) | |
tree | ae75ab12d5884f08dfac4774b542d49dad9ee896 /gcc/gimplify.c | |
parent | e1f217ad105cde2a7a34297fc7027655a93e75ac (diff) | |
download | gcc-220d905f7c53b81c4572450f9caf6197b2cc6c02.zip gcc-220d905f7c53b81c4572450f9caf6197b2cc6c02.tar.gz gcc-220d905f7c53b81c4572450f9caf6197b2cc6c02.tar.bz2 |
re PR debug/58123 (debug line not tracked for last autovariable dtor)
PR debug/58123
* gimplify.c (gimplify_expr): Prefer location of TRY_FINALLY_EXPR
over input_location.
From-SVN: r220886
Diffstat (limited to 'gcc/gimplify.c')
-rw-r--r-- | gcc/gimplify.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gcc/gimplify.c b/gcc/gimplify.c index 1353ada..d822913 100644 --- a/gcc/gimplify.c +++ b/gcc/gimplify.c @@ -8244,10 +8244,10 @@ gimplify_expr (tree *expr_p, gimple_seq *pre_p, gimple_seq *post_p, TREE_CODE (*expr_p) == TRY_FINALLY_EXPR ? GIMPLE_TRY_FINALLY : GIMPLE_TRY_CATCH); - if (LOCATION_LOCUS (saved_location) != UNKNOWN_LOCATION) - gimple_set_location (try_, saved_location); - else + if (EXPR_HAS_LOCATION (save_expr)) gimple_set_location (try_, EXPR_LOCATION (save_expr)); + else if (LOCATION_LOCUS (saved_location) != UNKNOWN_LOCATION) + gimple_set_location (try_, saved_location); if (TREE_CODE (*expr_p) == TRY_CATCH_EXPR) gimple_try_set_catch_is_cleanup (try_, TRY_CATCH_IS_CLEANUP (*expr_p)); |