use sampi::{Sampi, SampiData, SampiKeyPair}; fn main() -> anyhow::Result<()> { let kp = SampiKeyPair::new(); let data = "Hello World! 你好!".to_string(); let sampi = kp.new_sampi().build(vec![SampiData::String(data)])?; let bytes = sampi.to_bytes(); for _ in 0..100_000 { let _ = Sampi::from_bytes(&bytes)?; } Ok(()) }