AI RESEARCH

Raw Pointer Rewriting with LLMs for Translating C to Safer Rust

arXiv CS.AI

ArXi:2505.04852v3 Announce Type: replace-cross There has been a growing interest in translating C code to Rust due to Rust's robust memory and thread safety guarantees. Tools such as C2RUST enable syntax-guided transpilation from C to semantically equivalent Rust code. However, the resulting Rust programs often rely heavily on unsafe constructs, particularly raw pointers, which undermines Rust's safety guarantees. This paper aims to improve the memory safety of Rust programs generated by C2RUST by eliminating raw pointers.