Spaces:
Sleeping
Sleeping
| use pyo3::prelude::*; | |
| fn hello(name: &str) -> PyResult<String> { | |
| Ok(format!("Hello, {}! Welcome from Rust 🦀", name)) | |
| } | |
| fn sample_rust(_py: Python, m: &PyModule) -> PyResult<()> { | |
| m.add_function(wrap_pyfunction!(hello, m)?)?; | |
| Ok(()) | |
| } |