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 #1602 Date: Wed, 19 Oct 2022 19:45:38 +0000 (GMT) [thread overview] Message-ID: <20221019194538.8F968385841F@sourceware.org> (raw) https://gcc.gnu.org/g:9ecbc9008748672b1a47fab6d40ebe5a31507969 commit 9ecbc9008748672b1a47fab6d40ebe5a31507969 Merge: 381e0614388 0a52177612f Author: bors[bot] <26634292+bors[bot]@users.noreply.github.com> Date: Wed Oct 19 17:04:07 2022 +0000 Merge #1602 1602: Add check for recursive trait cycles r=philberty a=philberty This adds a new RAII style TraitQueryGuard so that we can manage the query lifetime when resolving a trait. This adds in a DefId into a set when we begin to resolve and then finally removes it when completed. This allows us to add in a check at the start if this DefId is already within the set which means this is a trait cycle. Fixes #1589 Co-authored-by: Philip Herron <philip.herron@embecosm.com> Diff: gcc/rust/typecheck/rust-hir-trait-resolve.cc | 12 +++++++++++- gcc/rust/typecheck/rust-hir-type-check.h | 29 ++++++++++++++++++++++++++++ gcc/testsuite/rust/compile/issue-1589.rs | 5 +++++ 3 files changed, 45 insertions(+), 1 deletion(-)
reply other threads:[~2022-10-19 19:45 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=20221019194538.8F968385841F@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: 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).