About switch case statements...

Ellery Newcomer ellery-newcomer at utulsa.edu
Mon Nov 16 15:33:09 PST 2009


Andrei Alexandrescu wrote:
> Ellery Newcomer wrote:
>> Andrei Alexandrescu wrote:
>>> Ellery Newcomer wrote:
>>>> KennyTM~ wrote:
>>>>> throw ...;
>>>>> assert(...);
>>>>>
>>>> you can call functions which do these...
>>> ... which is where the "none"/"bottom" type comes into play!
>>>
>>> Andrei
>>
>> What what?
> 
> http://en.wikipedia.org/wiki/Bottom_type
> http://www.cs.washington.edu/research/projects/cecil/www/Release/doc-cecil-stdlib/node4.html
> 
> 
> I gave a talk about similar stuff once but I don't know where it is. I
> also have 70% of an article on it written (and with a funny introduction
> to boot) but I couldn't find the time * interest to finish.
> 
> 
> Andrei

So a function that always throws should have a result type (maximal
type?) of bottom type?



More information about the Digitalmars-d mailing list