Automatically Translating C to Rust.

Migrating legacy systems from C to Rust offers a promising path to improve software reliability due to Rust’s strong safety guarantees. Automatic translators can assist this process, but current tools often produce code that is unsafe or unidiomatic, relying on features not fully validated by the Ru...

Descripción completa

Detalles Bibliográficos
Publicado en:Communications of the ACM Vol. 68; no. 11; pp. 58 - 66
Autores principales: Hong, Jaemin, Ryu, Sukyoung
Formato: Artículo
Publicado: Association for Computing Machinery Nov2025
Materias:
Acceso en línea:Ver este registro en EBSCOhost
Descripción
Sumario:Migrating legacy systems from C to Rust offers a promising path to improve software reliability due to Rust’s strong safety guarantees. Automatic translators can assist this process, but current tools often produce code that is unsafe or unidiomatic, relying on features not fully validated by the Rust compiler. The use of carefully designed static analyses and code transformations can enhance translations by replacing unsafe constructs with safe, idiomatic alternatives. Additionally, large language models present a potential approach to C-to-Rust translation, though they frequently introduce type errors or behavioral deviations, suggesting that combining large language models with static analysis could be a fruitful direction for future research.