Skip to content

always eagerly eval consts in Relate #81309

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Merged
merged 2 commits into from
Mar 10, 2021
Merged

Conversation

lcnr
Copy link
Contributor

@lcnr lcnr commented Jan 23, 2021

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jan 23, 2021
@@ -1,11 +1,11 @@
error[E0308]: mismatched types
Copy link
Contributor Author

@lcnr lcnr Jan 23, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

without this PR, this test causes the following output:

error[E0308]: mismatched types
  --> $DIR/const-argument-cross-crate-mismatch.rs:9:67
   |
LL |     let _ = const_generic_lib::function(const_generic_lib::Struct([0u8, 1u8]));
   |                                                                   ^^^^^^^^^^ expected `3_usize`, found `2_usize`
   |
   = note: expected array `[u8; 3]`
              found array `[u8; 2]`

error[E0308]: mismatched types
  --> $DIR/const-argument-cross-crate-mismatch.rs:11:65
   |
LL |     let _: const_generic_lib::Alias = const_generic_lib::Struct([0u8, 1u8, 2u8]);
   |                                                                 ^^^^^^^^^^^^^^^ expected `2_usize`, found `3_usize`
   |
   = note: expected array `[u8; 2]`
              found array `[u8; 3]`

error: aborting due to 2 previous errors

@lcnr lcnr added A-const-generics Area: const generics (parameters and arguments) F-lazy_normalization_consts labels Jan 23, 2021
@camelid camelid added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Feb 12, 2021
@JohnCSimon JohnCSimon added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Mar 1, 2021
@Dylan-DPC-zz
Copy link

@nikomatsakis any updates on this?

@nikomatsakis
Copy link
Contributor

So...I'm not 100% sure what I think about this, mostly because I feel like i'm lacking overall context about the "plan", but given that it seems to only affect code that opts into lazy-norm of constants...

@bors r+

@bors
Copy link
Collaborator

bors commented Mar 9, 2021

📌 Commit 2beea2c has been approved by nikomatsakis

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Mar 9, 2021
Dylan-DPC-zz pushed a commit to Dylan-DPC-zz/rust that referenced this pull request Mar 9, 2021
…akis

always eagerly eval consts in Relate

r? `@nikomatsakis` cc `@varkor`
Dylan-DPC-zz pushed a commit to Dylan-DPC-zz/rust that referenced this pull request Mar 9, 2021
…akis

always eagerly eval consts in Relate

r? ``@nikomatsakis`` cc ``@varkor``
bors added a commit to rust-lang-ci/rust that referenced this pull request Mar 10, 2021
Rollup of 9 pull requests

Successful merges:

 - rust-lang#81309 (always eagerly eval consts in Relate)
 - rust-lang#82217 (Edition-specific preludes)
 - rust-lang#82807 (rustdoc: Remove redundant enableSearchInput function)
 - rust-lang#82924 (WASI: Switch to crt1-command.o to enable support for new-style commands)
 - rust-lang#82949 (Do not attempt to unlock envlock in child process after a fork.)
 - rust-lang#82955 (fix: wrong word)
 - rust-lang#82962 (Treat header as first paragraph for shortened markdown descriptions)
 - rust-lang#82976 (fix error message for copy(_nonoverlapping) overflow)
 - rust-lang#82977 (Rename `Option::get_or_default` to `get_or_insert_default`)

Failed merges:

r? `@ghost`
`@rustbot` modify labels: rollup
@bors
Copy link
Collaborator

bors commented Mar 10, 2021

⌛ Testing commit 2beea2c with merge f98721f...

@bors bors merged commit 49bf48a into rust-lang:master Mar 10, 2021
@rustbot rustbot added this to the 1.52.0 milestone Mar 10, 2021
@lcnr lcnr deleted the lazy-norm-err-msgh branch December 11, 2021 17:16
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
A-const-generics Area: const generics (parameters and arguments) S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants