Type Inference for Struct/Enum Literals
harakim
harakim at gmail.com
Mon Jul 22 01:17:19 UTC 2024
On Friday, 5 July 2024 at 13:19:44 UTC, IchorDev wrote:
For any context where an enum literal or
> struct literal is being assigned/passed/etc. to something with
> a known type, allow us to omit the type from the literal.
I would suggest tackling these one at a time.
As for me, I have always wondered why you can't just type the
name of the enum instead of qualifying it. I like the syntax of
not prefix.
Also, I think editions should be free to break quite a bit of
stuff so long as 1. you can keep compiling older editions and 2.
there is a clear path from edition to edition that doesn't take a
lot of re-engineering. I would definitely move away from using _
or something like that because that is a very common variable
name.
Why do you not like the prefixless solution?
More information about the dip.ideas
mailing list