typescript·TypeScriptbydanhab99 Typescript is implementing a using keywordhttps://www.totaltypescript.com/typescript-5-2-new-keyword-usingOpen linkView original on programming.dev20Comments5
Kogasa replyprogramming.dev1Hide 1 replyDiscriminated unions have been In The Works(tm) for quite a while. I believe they were cut from the C# 12 roadmap. But maybe C# 13? I think a source-generation based approach similar to OneOf isn't unlikely.3
LLmaydev replyprogramming.devYeah unfortunately tacking them onto a 20 year old language is not easy. It's great to see it being worked on but there is a long way to go.1
nnickel programming.dev1Hide 1 replyDoes using function as a const? Meaning: when a using variable is declared, is it immutable?1
burkybang replyprogramming.devThis comment sounds like you’re having a stroke if we didn’t know the context.1
Discriminated unions have been In The Works(tm) for quite a while. I believe they were cut from the C# 12 roadmap. But maybe C# 13?
I think a source-generation based approach similar to
OneOfisn't unlikely.Yeah unfortunately tacking them onto a 20 year old language is not easy.
It's great to see it being worked on but there is a long way to go.
That seems quite useful
Does using function as a const? Meaning: when a using variable is declared, is it immutable?
This comment sounds like you’re having a stroke if we didn’t know the context.