public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc/devel/rust/master] Merge #1241
@ 2022-06-08 12:49 Thomas Schwinge
0 siblings, 0 replies; only message in thread
From: Thomas Schwinge @ 2022-06-08 12:49 UTC (permalink / raw)
To: gcc-cvs
https://gcc.gnu.org/g:63762cc243c643c10aca7e07dfd6abe9b78748f8
commit 63762cc243c643c10aca7e07dfd6abe9b78748f8
Merge: c7008d3e254 a91b138bbc2
Author: bors[bot] <26634292+bors[bot]@users.noreply.github.com>
Date: Mon May 23 14:28:23 2022 +0000
Merge #1241
1241: Implement name resolution for the IfLet expression. r=philberty a=antego
Addresses #1177.
Guidance from the ticket #1177:
> You should be able to copy how we do name resolution for the if blocks from that file. Though if let statements add a new binding and scope level so you need to declare the pattern so you should be able to see how that is done from rust-ast-resolve-stmt.
I don't understand how to modify the block expression resolution so that it can handle the `IfLet` expression. For now, I copied the code from the `MatchExpr` resolution. Not sure how to test it either and what is the desired expected result of the name resolution so I just hope that reviewers will spot the errors.
I created this PR in order to get some guidance about how to proceed with it. Thanks!
Co-authored-by: antego <antego@users.noreply.github.com>
Diff:
gcc/rust/resolve/rust-ast-resolve-expr.cc | 25 +++++++++++++++++++++++++
gcc/rust/resolve/rust-ast-resolve-expr.h | 2 ++
2 files changed, 27 insertions(+)
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-06-08 12:49 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-06-08 12:49 [gcc/devel/rust/master] Merge #1241 Thomas Schwinge
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).