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

ices/90871-1.rs: fixed with errors #1357

Merged
merged 1 commit into from
Jul 28, 2022
Merged

Conversation

github-actions[bot]
Copy link
Contributor

Issue: rust-lang/rust#90871

fn main() {
    2: n([u8; || 1])
}
=== stdout ===
=== stderr ===
error[E0412]: cannot find type `n` in this scope
 --> /home/runner/work/glacier/glacier/ices/90871-1.rs:2:8
  |
2 |     2: n([u8; || 1])
  |        ^ expecting a type here because of type ascription

error[E0308]: mismatched types
 --> /home/runner/work/glacier/glacier/ices/90871-1.rs:2:15
  |
2 |     2: n([u8; || 1])
  |               ^^^^ expected `usize`, found closure
  |
  = note: expected type `usize`
          found closure `[closure@/home/runner/work/glacier/glacier/ices/90871-1.rs:2:15: 2:17]`
help: use parentheses to call this closure
  |
2 |     2: n([u8; (|| 1)()])
  |               +    +++

error: aborting due to 2 previous errors

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

=== stdout ===
=== stderr ===
error[E0412]: cannot find type `n` in this scope
 --> /home/runner/work/glacier/glacier/ices/90871-1.rs:2:8
  |
2 |     2: n([u8; || 1])
  |        ^ expecting a type here because of type ascription

error[E0308]: mismatched types
 --> /home/runner/work/glacier/glacier/ices/90871-1.rs:2:15
  |
2 |     2: n([u8; || 1])
  |               ^^^^ expected `usize`, found closure
  |
  = note: expected type `usize`
          found closure `[closure@/home/runner/work/glacier/glacier/ices/90871-1.rs:2:15: 2:17]`
help: use parentheses to call this closure
  |
2 |     2: n([u8; (|| 1)()])
  |               +    +++

error: aborting due to 2 previous errors

Some errors have detailed explanations: E0308, E0412.
For more information about an error, try `rustc --explain E0308`.
==============
@Alexendoo Alexendoo merged commit 59c8820 into master Jul 28, 2022
@Alexendoo Alexendoo deleted the autofix/ices/90871-1.rs branch July 28, 2022 11:17
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