On Mon, Apr 16, 2012 at 3:22 PM, Graydon Hoare <gray...@mozilla.com> wrote:
> - Our records are order-sensitive, to be C-structure compatible. > Keyword arguments are usually argued-for (as you are doing here) as > a way to make function arguments order-insensitive. We'd need to > decide whether we wanted order to matter or not. > Could the compiler just reorder them behind the scenes? Then records could remain order-sensitive internally, and order mattering would be a non-issue. As a tangent, I have found the best use of keyword args to be made by Python, where they enable arbitrary parameters to have defaults (as opposed to c++ style, where default arguments can only be given from the final parameter backwards).
_______________________________________________ Rust-dev mailing list Rust-dev@mozilla.org https://mail.mozilla.org/listinfo/rust-dev