Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

> The "enforce preconditions via types" is a common pattern in Rust

Called the Type State Pattern. Here are two links from my bookmarks:

https://cliffle.com/blog/rust-typestate/

https://yoric.github.io/post/rust-typestate/



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: