Fixing C's Biggest Mistake

Max Samukha maxsamukha at gmail.com
Wed Jan 11 10:57:18 UTC 2023


On Wednesday, 11 January 2023 at 08:57:25 UTC, Guillaume Piolat 
wrote:
> On Wednesday, 11 January 2023 at 00:02:30 UTC, A moo person 
> wrote:
>>
>> There are definitely cases where it is desirable. In games, 
>> especially competitive real time games, the show must go on. 
>> If you are in a high adrenalin match and your game crashes at 
>> the worst time because some animation system got into an 
>> invalid state, you will be very mad.
>
> We need to caracterize where it's ok to go on, typically it's 
> cases where showing errors in would be worse for the user, and 
> the user is creating some "content".
>
> - Markdown has a design where it always compile. No errors 
> because erros have a visual impact, and in content creation if 
> it has no visual impact it's not a real error.
>
> - typically a game engine: if a file failed to load
>
> - HTML and CSS are famously lenient
>
> But all those cases are "input errors", not "invalid state".

I used to buy into the propaganda of the distinction between 
"input" and "logic" errors. Now I beleive the distinction is 
moslty useless. "Invalid state" becomes "input error" depending 
on how you modularize the system.


More information about the Digitalmars-d mailing list