1
Fork 0

remove support for rustc_intrinsic_must_be_overridden from the compiler

This commit is contained in:
Ralf Jung 2025-02-23 17:34:50 +01:00
parent 5a58a922e2
commit 6eea027aa9
24 changed files with 70 additions and 203 deletions

View file

@ -7,12 +7,8 @@ Erroneous code example:
#![allow(internal_features)]
#[rustc_intrinsic]
#[rustc_intrinsic_must_be_overridden]
fn size_of<T, U>() -> usize // error: intrinsic has wrong number
// of type parameters
{
loop {}
}
fn size_of<T, U>() -> usize; // error: intrinsic has wrong number
// of type parameters
```
Please check that you provided the right number of type parameters
@ -24,9 +20,5 @@ Example:
#![allow(internal_features)]
#[rustc_intrinsic]
#[rustc_intrinsic_must_be_overridden]
fn size_of<T>() -> usize // ok!
{
loop {}
}
fn size_of<T>() -> usize; // ok!
```