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

ices/83837.rs: fixed with errors #1011

Merged
merged 1 commit into from
Nov 10, 2021
Merged

ices/83837.rs: fixed with errors #1011

merged 1 commit into from
Nov 10, 2021

Conversation

github-actions[bot]
Copy link
Contributor

Issue: rust-lang/rust#83837

#![feature(staged_api)]
struct u16x2(u16, u16);
extern "platform-intrinsic" {
    #[rustc_const_stable(feature = "foo", since = "1.3.37")]
    fn simd_insert(x: T, idx: u32, val: U);
}
fn main() {
    const U: u16x2 = u16x2(13, 14);
    const { simd_insert(U, 0x1319_8a2e, 42_u16) }
}
=== stdout ===
=== stderr ===
error[E0412]: cannot find type `T` in this scope
 --> /home/runner/work/glacier/glacier/ices/83837.rs:5:23
  |
5 |     fn simd_insert(x: T, idx: u32, val: U);
  |                       ^ not found in this scope

error[E0412]: cannot find type `U` in this scope
 --> /home/runner/work/glacier/glacier/ices/83837.rs:5:41
  |
5 |     fn simd_insert(x: T, idx: u32, val: U);
  |                                         ^ not found in this scope

error[E0658]: inline-const is experimental
 --> /home/runner/work/glacier/glacier/ices/83837.rs:9:5
  |
9 |     const { simd_insert(U, 0x1319_8a2e, 42_u16) }
  |     ^^^^^
  |
  = note: see issue #76001 <https://github.com/rust-lang/rust/issues/76001> for more information
  = help: add `#![feature(inline_const)]` to the crate attributes to enable

error[E0658]: platform intrinsics are experimental and possibly buggy
 --> /home/runner/work/glacier/glacier/ices/83837.rs:3:8
  |
3 | extern "platform-intrinsic" {
  |        ^^^^^^^^^^^^^^^^^^^^
  |
  = note: see issue #27731 <https://github.com/rust-lang/rust/issues/27731> for more information
  = help: add `#![feature(platform_intrinsics)]` to the crate attributes to enable

warning: type `u16x2` should have an upper camel case name
 --> /home/runner/work/glacier/glacier/ices/83837.rs:2:8
  |
2 | struct u16x2(u16, u16);
  |        ^^^^^ help: convert the identifier to upper camel case (notice the capitalization): `U16x2`
  |
  = note: `#[warn(non_camel_case_types)]` on by default

error[E0094]: intrinsic has wrong number of type parameters: found 0, expected 2
 --> /home/runner/work/glacier/glacier/ices/83837.rs:5:19
  |
5 |     fn simd_insert(x: T, idx: u32, val: U);
  |                   ^ expected 2 type parameters

error: aborting due to 5 previous errors; 1 warning emitted

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

=== stdout ===
=== stderr ===
error[E0412]: cannot find type `T` in this scope
 --> /home/runner/work/glacier/glacier/ices/83837.rs:5:23
  |
5 |     fn simd_insert(x: T, idx: u32, val: U);
  |                       ^ not found in this scope

error[E0412]: cannot find type `U` in this scope
 --> /home/runner/work/glacier/glacier/ices/83837.rs:5:41
  |
5 |     fn simd_insert(x: T, idx: u32, val: U);
  |                                         ^ not found in this scope

error[E0658]: inline-const is experimental
 --> /home/runner/work/glacier/glacier/ices/83837.rs:9:5
  |
9 |     const { simd_insert(U, 0x1319_8a2e, 42_u16) }
  |     ^^^^^
  |
  = note: see issue #76001 <rust-lang/rust#76001> for more information
  = help: add `#![feature(inline_const)]` to the crate attributes to enable

error[E0658]: platform intrinsics are experimental and possibly buggy
 --> /home/runner/work/glacier/glacier/ices/83837.rs:3:8
  |
3 | extern "platform-intrinsic" {
  |        ^^^^^^^^^^^^^^^^^^^^
  |
  = note: see issue #27731 <rust-lang/rust#27731> for more information
  = help: add `#![feature(platform_intrinsics)]` to the crate attributes to enable

warning: type `u16x2` should have an upper camel case name
 --> /home/runner/work/glacier/glacier/ices/83837.rs:2:8
  |
2 | struct u16x2(u16, u16);
  |        ^^^^^ help: convert the identifier to upper camel case (notice the capitalization): `U16x2`
  |
  = note: `#[warn(non_camel_case_types)]` on by default

error[E0094]: intrinsic has wrong number of type parameters: found 0, expected 2
 --> /home/runner/work/glacier/glacier/ices/83837.rs:5:19
  |
5 |     fn simd_insert(x: T, idx: u32, val: U);
  |                   ^ expected 2 type parameters

error: aborting due to 5 previous errors; 1 warning emitted

Some errors have detailed explanations: E0094, E0412, E0658.
For more information about an error, try `rustc --explain E0094`.
==============
@Alexendoo Alexendoo merged commit 18ea60e into master Nov 10, 2021
@Alexendoo Alexendoo deleted the autofix/ices/83837.rs branch November 10, 2021 13:28
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