I've been using Scala for years and have been eying Rust for a while. Nice to see lots of the things I like from Scala carry over. In particular this seems like a less magical version of Scala implicits, which seem incredibly cool at first until you realize that a particular library or framework implements implicits for everything, and tracking down the source for a given function involves guessing the signature or chasing down an implicit implicit conversion chain that gets you to one.<p>One thing I'm not sure about though, the article talks about implementing the Into trait, then quickly segues over to From. When would I use Into, when From, and do they both lead to the same end (I.e. a function that takes Into<Whatever>?) I've looked at the docs for each, and maybe I just haven't had enough coffee yet but the distinction isn't too clear.
I still have the scars from libraries implementing implicit conversions in c++.<p>The question is - for people reading the code at the call site, how easy is it to grep for what's actually happening?<p>I guess this rust trait at least hangs off the geobox class, but I think I might prefer the explicit ctor for non write-only code.
Hmm. <i>Can</i> you...<p><pre><code> impl From<T> for GeoBox
</code></pre>
... outside the module/crate in which GeoBox is defined (as suggested at the end)?