2 ms·
Method calls are syntax sugar in Rust; it compiles to the same code as atan2(y, x). The only difference is it will auto ref for you in the method style. You can
by steveklabnik 8y ago
Method calls are syntax sugar in Rust; it compiles to the same code as atan2(y, x). The only difference is it will auto ref for you in the method style. You can call it either way if you prefer. Those are just regular floats, not objects.
Some is an enum constructor that’s in the prelude, so it’s just automatically imported. It’s a library type, nothing specially built into the language.