On Thu, May 29, 2014 at 7:01 PM, Tommi <[email protected]> wrote: > The lack of function overloading forces us to have two differently named > functions, say `foo_a` and `foo_b`, and the programmer has to keep in mind > that if he wants the optimized algorithm, then he needs to call `foo_b` > (instead of `foo_a`) if his argument implements `B`.
I would consider this usually an upside, because this way the programmer knows whether the fast or slow version is being used, and that calling the slow version may be a hazard to be improved by refactoring the code to implement B. It may occasionally be a downside. _______________________________________________ Rust-dev mailing list [email protected] https://mail.mozilla.org/listinfo/rust-dev
