|
|
|
|
|
by bccdee
280 days ago
|
|
> Up to and including requiring proof that a function's domain is respected Does such a proof exist in this context? Or are we writing fanfiction about the problem domain now? > It's not "unrecoverable" Yes it is. The correct behaviour in that context is to terminate the program, which makes it unrecoverable. |
|
"Often HPC codebases will use numerical schemes which are mathematically proven to 'blow up' (produce infs/nans) under certain conditions even with a perfect implementation"
Yes? Function domains are trivially enforceable through the type system when you have dependent types. Even the n-dimensional case of the CFL condition is a simple constraint you can express over a type.
Have you ever actually done any work with dependent types? I'm not sure why you would think something so basic as enforcing a function domain (which isn't the same thing as a problem domain, by the way) would be "fanfiction" otherwise. I highly recommend spending a few months actually working with them, there are plenty of good languages floating around these days.
> The correct behaviour in that context is to terminate the program
At worst it's to leave the thread of execution, which is distinct from crashing, as you asserted above and as my core point revolves around.