`type_name` of an async fn future fails the build
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 4/5
- Tempo stimato
- 3-5 giorni
- Idoneità per principianti
- 48/100
- Tipo di issue
- Bug
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Stack tecnologico
- rust
- Ambito
- build-system
Direzione di ricerca
Start by reproducing the failure with the minimal src/main.rs example using cargo rustd build. Trace how the Cranelift backend handles std::any::type_name for an async function future, then compare with the related async block layout issue #13. Done when the workspace loads successfully for this example and the reported tokio/axum dependency case is addressed.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
std::any::type_name (or type_name_of_val) on the future of an async fn fails the build. Plain cargo run prints tn::work::{{closure}}.
cargo new tn, then replace src/main.rs with:
async fn work() -> u32 { 1 }
fn main() {
let fut = work();
println!("{}", std::any::type_name_of_val(&fut));
}
$ cargo rustd build
Finished `dev` profile [unoptimized + debuginfo] target(s) in 0.27s
error: the daemon could not load the workspace (exit status: 1: Error: `tn[bee6a96e4e266f05]::main` is not compiled by rustd: unsupported: callee `type_name`: unsupported: `type_name` of `Coroutine(InternedCoroutineId(InternedCoroutineId { key: ClosureKey { owner: DefWithBodyId(FunctionId(FunctionId(60ed9))), nth: 0, kind: Coroutine { kind: Async, source: Fn } } }), [(), (), (), u32, ()])`)
It first showed up in a tokio/axum workspace, where a dependency calls type_name on a future reached from block_on, so the whole program fails to load.
Not #13: that one is the layout of an async block.
- Linux aarch64 (Docker
rust:1.99.0): rustd0.0.0-42f6848-18e83ddffac1f84c - macOS 27.2.1 aarch64, Rust 1.99.0: rustd
0.0.0-3b0efc0-18e83c724da35926, same error - Both from the install script (the
nightlyrelease of 2026-10-21), Cranelift backend
Authored by Claude (claude-opus-5-5).
- Lingua principale
- Rust
- Stelle
- 248
- Fork
- 13
- Merge medio
- 7h 52m
- PR unite (30g)
- 5
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di DioxusLabs/rustd
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 78/100
DioxusLabs/rustd#15 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 35/100
DioxusLabs/rustd#27 ·
I maintainer di solito rispondono entro 1 giorno
-
Workspace fails to load: rquickjs types give layout of …: HasErrorType, and rustd never falls backAperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 25/100
DioxusLabs/rustd#26 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 65/100
DioxusLabs/rustd#25 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 50/100
DioxusLabs/rustd#24 · 1 reazione ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di DioxusLabs/rustd
Issue simili
-
Bump Python to 3.14 or 3.15Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno
-
bug rust
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 2 giorni
-
type: bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 67/100
franciscoBSalgueiro/en-croissant#1111 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 74/100
oxc-project/oxc-htmlish-parser#34 ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
longbridge/nsh#2541 ·
I maintainer di solito rispondono entro 1 giorno