News for hackers. Stuff that matters.
Re:Python 3.11 vs 3.10 performance by tialaramex on Wednesday July 06, 2022 @06:46PM (#32007853)
Your parent is thinking about the compiler errors, whereas std::io::Error (which I'm guessing you mean) is an Error type your software can get from calling I/O functions at runtime.

To be fair, if decorating the error with information about a filename is what you needed, since Rust's Error types are just types nothing stops you making your function's Error type be the tuple (std::io::Error, &str) if you have a string reference, or (though this seems terribly inappropriate in production code) leaking a Box to make a static reference from a string whose lifetime isn't sufficient.

There are no comments on this comment yet.