public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
From: Thomas Schwinge <tschwinge@gcc.gnu.org>
To: gcc-cvs@gcc.gnu.org
Subject: [gcc/devel/rust/master] Merge #1220 #1221
Date: Wed,  8 Jun 2022 12:44:49 +0000 (GMT)	[thread overview]
Message-ID: <20220608124449.68CC238936EE@sourceware.org> (raw)

https://gcc.gnu.org/g:3b8f3e61394f27100fb788a839e61f8b753f502b

commit 3b8f3e61394f27100fb788a839e61f8b753f502b
Merge: 74e836599ce 224647d24a3 0d8c2984436
Author: bors[bot] <26634292+bors[bot]@users.noreply.github.com>
Date:   Mon May 9 10:11:28 2022 +0000

    Merge #1220 #1221
    
    1220: Ensure the coercion sites are applied correctly on unions r=philberty a=philberty
    
    When we construct a union, we were wrongly compiling the constructor
    without taking into account the associated union index. This meant we
    if you were constructing a union using any other field than the first one
    you had a bad coercion type check resulting in a silent failure of generating
    an error_mark_node.
    
    This was caught using an assertion to ensure there is no error on coercion site but it is valid
    to have errors from coercion sites.
    
    1221: Ensure we don't return error_mark_node for loop expressions r=philberty a=philberty
    
    Loop expressions can return a value even if its a unit-type so we must
    ensure we don't return an error_mark_node for the eventual coercion site
    for the unit-type case.
    
    The offending test-case was: rust/compile/torture/loop7.rs
    
    This was found while fixing #1220
    
    
    Co-authored-by: Philip Herron <philip.herron@embecosm.com>

Diff:

 gcc/rust/backend/rust-compile-expr.h | 80 ++++++++++++++++++++++++------------
 1 file changed, 53 insertions(+), 27 deletions(-)


                 reply	other threads:[~2022-06-08 12:44 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=20220608124449.68CC238936EE@sourceware.org \
    --to=tschwinge@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: link
Be 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).