Re: Haskell is our first choice for building production soft...
by silluk on Monday January 11, 2021 @11:25AM
(#25731130)
To me it's not the trivial cases like this that make type inference useful. It's when you get longer types like `Arc<Mutex<HashMap<String, String>>>`. Granted, that could be solved with a `type` declaration (or `typedef` in C++) but it's still convenient to be able to say: `let mut x = Arc::new(Mutex::new(HashMap::new()));` and let the compiler figure out the rest based on usage.
[ Parent
| on HN ]
There are no comments on this comment yet.