3 ms·
Really interesting concepts here, especially subscripts (which neatly solve an issue that RAAI semantics or lambdas are usually hacked into solving). Is my rea
by zamalek 3y ago
Really interesting concepts here, especially subscripts (which neatly solve an issue that RAAI semantics or lambdas are usually hacked into solving).
Is my reading of overloads correct? Identically-named methods are supported, but only for different argument labels and/or calling conventions?
Rust convinced me that dispatching based on argument types is a poor idea, because Vec::new(10) could only be understood by reading the documentation at least once - whereas Vec::with_capacity(10) is abundantly clear. Val seems to gain these benefits (assuming that it doesn't dispatch based on type) without the drawbacks.
- adamwk 3y agoYou're correct; Since argument labels are really part of the function name, you can say all function names must be unique
- germandiago 3y agoWhat about generic code?