minirust icon indicating copy to clipboard operation
minirust copied to clipboard

minimize: Add support for and `FnDef`

Open bifbof opened this issue 8 months ago • 1 comments

Currently a function cannot be used except for calling it

fn f() {}
fn main() {
    let _ = f;
}

generates the following error message:

error: internal compiler error: minimize/src/ty.rs:92:18: TyKind not supported: FnDef(DefId(0:3 ~ temp_file[43f8]::f), [])
 --> tooling/minimize/fails/temp_file.rs:4:13
  |
4 |     let _ = f;
  |             ^

thread 'rustc' panicked at minimize/src/ty.rs:92:18:
Box<dyn Any>
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

bifbof avatar Jun 20 '24 14:06 bifbof