]> git.lizzy.rs Git - rust.git/blob - compiler/rustc_error_codes/src/error_codes/E0094.md
Rollup merge of #102215 - alexcrichton:wasm-link-whole-archive, r=estebank
[rust.git] / compiler / rustc_error_codes / src / error_codes / E0094.md
1 An invalid number of generic parameters was passed to an intrinsic function.
2
3 Erroneous code example:
4
5 ```compile_fail,E0094
6 #![feature(intrinsics)]
7
8 extern "rust-intrinsic" {
9     #[rustc_safe_intrinsic]
10     fn size_of<T, U>() -> usize; // error: intrinsic has wrong number
11                                  //        of type parameters
12 }
13 ```
14
15 Please check that you provided the right number of type parameters
16 and verify with the function declaration in the Rust source code.
17 Example:
18
19 ```
20 #![feature(intrinsics)]
21
22 extern "rust-intrinsic" {
23     #[rustc_safe_intrinsic]
24     fn size_of<T>() -> usize; // ok!
25 }
26 ```