>> I don't see why adding the tycon back introduces so much complexity, to
>> be honest.
> 
> It's 3 new AST nodes (an expr form, a type form, a pattern form) as well as a 
> new ty::t node, a new case in every stage in the compiler that interacts with 
> any of those, and new parsing logic in each of those grammars to handle 
> disambiguating comma in other contexts.
> 
> More significant than the amount-of-work to do it, is the ongoing (slight) 
> cognitive cost to all users. It adds these cases to everyone who has to think 
> about the language, tool it, write it, etc. That's the complexity I'm more 
> concerned about. I can hack up the code if need be.
> 
> We decided the cost-savings argument overruled the convenience argument last 
> time.

I don't agree. Tuples are familiar from many other languages, and not just 
egghead languages. Python, for example. And there's very little cognitive load: 
they're just structs but with anonymous fields. That's pretty simple.

In the bigger picture, Rust has so many more complex features that the 
complaint that tuples strain the complexity budget just doesn't sit right with 
me.

Dave

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

Reply via email to