DIP 1029---Add throw as Function Attribute---Community Review Round 1

Adam D. Ruppe destructionator at gmail.com
Wed Jan 15 17:40:16 UTC 2020


On Wednesday, 15 January 2020 at 17:34:46 UTC, Aliak wrote:
> It’s so that you are forced to be aware of functions that throw 
> and then you either handle it or not.

Ironically, this was one of the reasons given for exceptions 
being used in the first place.

And we have 25 years of history showing exceptions do a better 
job on reliability than the alternatives D currently offers.

It is possible that other techniques could be added to D, and 
then maybe we can revisit this decision after they prove 
themselves in practice. But as it is now, exceptions (and I'm 
critical of certain details of D's exceptions; strings considered 
harmful lol) are the best we have and discouraging them is a step 
backwards.


More information about the Digitalmars-d mailing list