{"library":"lua2rust","title":"lua2rust","description":"A transpiler that converts Lua source code to Rust. Current stable version 0.5.2. Release cadence is irregular with occasional updates. Key differentiator: it provides a direct path from Lua scripts to Rust code, though with significant limitations such as no support for metatables, loadstring, or user-defined iterators. It is best suited for simple Lua scripts that use basic constructs.","language":"javascript","status":"active","last_verified":"Fri May 01","install":{"commands":["npm install lua2rust"],"cli":{"name":"lua2rust","version":null}},"imports":["// no import; transpiled output is a Rust function","npx lua2rust script.lua my_function > output.rs"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"// Create a simple Lua script\n// test.lua:\nfunction greet(name)\n  return \"Hello, \" .. name\nend\n\nprint(greet(\"World\"))\n\n# Transpile to Rust\nnpx lua2rust test.lua greet > greet.rs\n\n// greet.rs will contain a Rust function corresponding to the Lua code.","lang":"javascript","description":"Demonstrates transpiling a simple Lua function to Rust using CLI.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}