On Wednesday, 20 June 2012 at 14:36:48 UTC, ixid wrote:
Is there any reason not to add this so you can use foo := bar
as a shorthand for auto foo = bar?
I would be against this change. There isn't much to say agaist it
especially since => was fairly recently added (though has more
benefit than I see here). The word auto is not hard to type for a
Dvorak user, it kind of just roles off (auto). Declarations would
then need to be identified by starting with auto or variable :=.
And on that similar point, Vim fails to go to declarations
already. While I don't anticipate trying to fix this anytime
soon, the new form would likely make this yet another thing to go
wrong.
Somewhere you made a comment about
const auto ...;
No, it is
const int ...;
You can't include auto if you are using const/immutable... but
you can include the actual type.