Rust errors / Everything else
Rust compiler error · checked with rustc 1.99.0
Rust error E0622: #### Note: this error code is no longer emitted by the compiler
What it means#### Note: this error code is no longer emitted by the compiler.
Retired: rustc no longer emits this error code. You may still see it in old answers, books and CI logs from older toolchains; the explanation below is kept for reference.
The compiler team's explanation
Note: this error code is no longer emitted by the compiler.
An intrinsic was declared without being a function.
Erroneous code example:
#![feature(intrinsics)]
#![allow(internal_features)]
extern "C" {
#[rustc_intrinsic]
pub static atomic_singlethreadfence_seqcst: unsafe fn();
// error: intrinsic must be a function
}
fn main() { unsafe { atomic_singlethreadfence_seqcst(); } }
An intrinsic is a function available for use in a given programming language whose implementation is handled specially by the compiler. In order to fix this error, just declare a function. Example:
#![feature(intrinsics)]
#![allow(internal_features)]
#[rustc_intrinsic]
pub unsafe fn atomic_singlethreadfence_seqcst(); // ok!
fn main() { unsafe { atomic_singlethreadfence_seqcst(); } }From rustc --explain E0622 (1.99.0), part of the Rust project, MIT or Apache-2.0. Official page.
Related errors
- E0061this function takes N arguments but M were supplied
- E0412cannot find type in this scope
- E0515cannot return reference to local variable
- E0728await is only allowed inside async functions and blocks
- E0606casting `&u8` as `u32` is invalid
- E0618expected function, found
- E0627yield expression outside of coroutine literal
- E0628too many parameters for a coroutine (expected 0 or 1 parameters)
Up next
Often hit nextE0061: this function takes N arguments but M were suppliedA related error from the same family.Read it next →Did this answer your question?