Re: [heycam/webidl] add a type to represent the undefined value (#60)

Sorry to bring this issue up, but I already miss the `void` type. As mentioned above `undefined foo()` sounds a little bit weird to me. I'd probably use `undefined` only if it has a *particular meaning*. For example, in a find function, I'd return undefined if I cannot find the value. 

On the other hand, `void` is useful to state that a function does not return anything. This is also how Typescript describes the `void` type: https://www.typescriptlang.org/docs/handbook/basic-types.html. I'd take inspiration from there and reintroduce the void type.  

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/heycam/webidl/issues/60#issuecomment-675969772

Received on Wednesday, 19 August 2020 08:50:31 UTC