public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Eric Botcazou <ebotcazou@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r10-9859] Fix incorrect SLOC on instruction Date: Fri, 21 May 2021 08:29:51 +0000 (GMT) [thread overview] Message-ID: <20210521082951.0EDA13848035@sourceware.org> (raw) https://gcc.gnu.org/g:f32045f12b3671d8cb241078e5e9ae98923edfe9 commit r10-9859-gf32045f12b3671d8cb241078e5e9ae98923edfe9 Author: Eric Botcazou <ebotcazou@adacore.com> Date: Fri May 21 10:26:50 2021 +0200 Fix incorrect SLOC on instruction This puts the missing SLOC on a statement generated by a return. gcc/ada/ * gcc-interface/trans.c (gnat_to_gnu) <N_Simple_Return_Statement>: Put a SLOC on the assignment from the return value to the return object in the copy-in/copy-out case. Diff: --- gcc/ada/gcc-interface/trans.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/gcc/ada/gcc-interface/trans.c b/gcc/ada/gcc-interface/trans.c index a2cbaae2326..334324152f8 100644 --- a/gcc/ada/gcc-interface/trans.c +++ b/gcc/ada/gcc-interface/trans.c @@ -8089,8 +8089,10 @@ gnat_to_gnu (Node_Id gnat_node) if (gnu_return_label_stack->last ()) { if (gnu_ret_val) - add_stmt (build_binary_op (MODIFY_EXPR, NULL_TREE, gnu_ret_obj, - gnu_ret_val)); + add_stmt_with_node (build_binary_op (MODIFY_EXPR, + NULL_TREE, gnu_ret_obj, + gnu_ret_val), + gnat_node); gnu_result = build1 (GOTO_EXPR, void_type_node, gnu_return_label_stack->last ());
reply other threads:[~2021-05-21 8:29 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20210521082951.0EDA13848035@sourceware.org \ --to=ebotcazou@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).