On 10-12-29 10:49 AM, Rafael Ávila de Espíndola wrote:
While hacking in the parser I noticed that

...ast.ident id....
let vec[ast.ident] identifiers = vec();
identifiers += id;

works, but that

let [email protected]_item] v = vec();
let @ast.meta_item x = @spanned(lo, hi, rec(name = name, value = name));
v += x;

doesn't. Is there a rationale for it? Chatting with dherman he expressed
a preference for + always requiring two vectors. I would second that, as
it looks more natural and is what is done in other languages. We can
always add an append method for when there is a single element to be added.


Yeah. Our conversation on IRC led us to the conclusion that it's probably not worth ripping out of rustboot in the short term, but we'll not support it in rustc (and probably figure out some kind of static binding mechanism for method-call-izing basic plain-data types).

If it annoys you enough, feel free to rip it out of rustboot and adjust the testcases to match. Or I can do it. Actually I'm in a kinda delete-y mood today. Maybe I'll do it.

-Graydon
_______________________________________________
Rust-dev mailing list
[email protected]
https://mail.mozilla.org/listinfo/rust-dev

Reply via email to