Skip to content
This repository was archived by the owner on May 23, 2024. It is now read-only.

ices/68542.rs: fixed with errors #275

Merged
merged 1 commit into from
Jan 29, 2020
Merged

ices/68542.rs: fixed with errors #275

merged 1 commit into from
Jan 29, 2020

Conversation

github-actions[bot]
Copy link
Contributor

Issue: rust-lang/rust#68542

struct Bug {
    a: [(); (|| { 0 })()]
}

fn main() {}
=== stdout ===
=== stderr ===
error[E0015]: calls in constants are limited to constant functions, tuple structs and tuple variants
 --> /home/runner/work/glacier/glacier/ices/68542.rs:2:13
  |
2 |     a: [(); (|| { 0 })()]
  |             ^^^^^^^^^^^^

error[E0080]: evaluation of constant value failed
 --> /home/runner/work/glacier/glacier/ices/68542.rs:2:13
  |
2 |     a: [(); (|| { 0 })()]
  |             ^^^^^^^^^^^^ calling non-const function `Bug::a::{{constant}}#0::{{closure}}#0`

error: aborting due to 2 previous errors

Some errors have detailed explanations: E0015, E0080.
For more information about an error, try `rustc --explain E0015`.
==============

=== stdout ===
=== stderr ===
error[E0015]: calls in constants are limited to constant functions, tuple structs and tuple variants
 --> /home/runner/work/glacier/glacier/ices/68542.rs:2:13
  |
2 |     a: [(); (|| { 0 })()]
  |             ^^^^^^^^^^^^

error[E0080]: evaluation of constant value failed
 --> /home/runner/work/glacier/glacier/ices/68542.rs:2:13
  |
2 |     a: [(); (|| { 0 })()]
  |             ^^^^^^^^^^^^ calling non-const function `Bug::a::{{constant}}#0::{{closure}}#0`

error: aborting due to 2 previous errors

Some errors have detailed explanations: E0015, E0080.
For more information about an error, try `rustc --explain E0015`.
==============
@Alexendoo Alexendoo merged commit eaf6d20 into master Jan 29, 2020
@Alexendoo Alexendoo deleted the autofix/ices/68542.rs branch January 29, 2020 12:09
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants