29 ms·
What about convert to AST then ask the AI to convert to Rust. Would that work?
by stogot 2y ago
What about convert to AST then ask the AI to convert to Rust. Would that work?
- Someone 2y agoThat’s probably the rout they would take, but the C AST won’t have ownership attributes. You‘d have to discover those yourself. ASTs also don’t have much info on threading (that’s more or less limited to “the program starts a thread with entry point foo at some time”, “Foo waits for another thread to finish”)
- morgante 2y agoFoundation models aren't primarily trained on ASTs, so you're typically going to have worse results than just using text unless you do extensive fine-tuning yourself. ASTs also generally don't actually have magical information in them. They won't solve the lifetime issues for you.