about summary refs log tree commit diff
path: root/compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2020-09-11 20:01:31 +0000
committerbors <bors@rust-lang.org>2020-09-11 20:01:31 +0000
commitbc57bd8c7e3e28f8bed4fced3973bfe04949918f (patch)
tree372467744979f76c18d225ac97010656bd524875 /compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp
parent141bb23be863f8bfe25ccac102c6e7b96b61d417 (diff)
parentc63f634a4b0550a398d5bf08f8b036edaf67c48d (diff)
downloadrust-bc57bd8c7e3e28f8bed4fced3973bfe04949918f.tar.gz
rust-bc57bd8c7e3e28f8bed4fced3973bfe04949918f.zip
Auto merge of #76499 - guswynn:priv_des, r=petrochenkov
Give better diagnostic when using a private tuple struct constructor

Fixes #75907

Some notes:
1. This required some deep changes, including removing a Copy impl for PatKind. If some tests fail, I would still appreciate review on the overall approach
2. this only works with basic patterns (no wildcards for example), and fails if there is any problems getting the visibility of the fields (i am not sure what the failure that can happen in resolve_visibility_speculative, but we check the length of our fields in both cases against each other, so if anything goes wrong, we fall back to the worse error. This could be extended to more patterns
3. this does not yet deal with #75906, but I believe it will be similar
4. let me know if you want more tests
5. doesn't yet at the suggestion that `@yoshuawuyts` suggested at the end of their issue, but that could be added relatively easily (i believe)
Diffstat (limited to 'compiler/rustc_llvm/llvm-wrapper/PassWrapper.cpp')
0 files changed, 0 insertions, 0 deletions