4 ms·
Yup, that's a good point, UFCS means that every method/function is free-standing =)
by Ar-Curunir 5y ago
Yup, that's a good point, UFCS means that every method/function is free-standing =)
- tialaramex 5y agoUniversal Function Call Syntax goes both ways, Rust only offers to treat all of the things that seem like "methods" as free functions but not the reverse. Under UFCS I could extend your Rust type by simply writing a new free function which matches the type, and this is in fact deliberately forbidden. (I can write the free function, but, doing so does not extend the type and I can't call it using the "method" syntax).