"Exceptions will fade away in modern languages"
Ola Fosheim Grostad
ola.fosheim.grostad at gmail.com
Wed Nov 25 11:10:57 UTC 2020
On Wednesday, 25 November 2020 at 11:05:06 UTC, Stefan Koch wrote:
> On Sunday, 22 November 2020 at 00:09:36 UTC, Ola Fosheim
> Grostad wrote:
>> On Saturday, 21 November 2020 at 23:05:19 UTC, IGotD- wrote:
>>> I reacted to the comment of Walter Bright about exceptions in
>>> the "Destroy All Memory Corruption" presentation. The point
>>> he made that exceptions don't play well with compile time
>>> data flow analysis. He also mentioned that he thinks that
>>> exception will become obsolete in the future. Exceptions are
>>> used in many languages today and even the newest ones so I
>>> can't see a trend here.
>> Exceptions can be modelled with conditionals in static
>> analysis. They should work out ok with dataflow analysis.
> Only with inter-procedural dataflow anlysis.
> Since @live's DFA if intra-procedural (does not the leave
> function body) it cannot model dataflow that may be continued
> in another functions frame.
> then again ... perhaps that's not actually and issue, but I
> haven't thought much about it.
I think you can do make worst case assumptions, but D should do
context senditive analysis. Basically, compile summaries (what
can it throw) for all functions before doing the live analysis.
It is common to do overapproximations (assume too much, but
More information about the Digitalmars-d