Re: No exceptions?
From: Bob Badour <bbadour_at_pei.sympatico.ca>
Date: Fri, 30 Jun 2006 18:46:27 GMT
Message-ID: <7kepg.4227$pu3.99526_at_ursa-nb00s0.nbnet.nb.ca>
>
> Don't forget the converse problem - there was a relation y at compile
> time that was removed before runtime; there's no way to generate a
> compile time exception for the unexceptionable, but there are not many
> ways of avoiding a runtime exception if the compile time y had defined
> attributes (was not a synonym of DEE or DUM). Obviously, you could
> reinterpret the entire program in the light of what you find at runtime,
> but then why bother with the compilation in the first place? Even
> within a single program, you could have a relation y available when it
> is first interpreted that is dropped by the time the statement
> referencing it is executed. So, some runtime exceptions are nigh-on
> unavoidable, I think.
Date: Fri, 30 Jun 2006 18:46:27 GMT
Message-ID: <7kepg.4227$pu3.99526_at_ursa-nb00s0.nbnet.nb.ca>
Jonathan Leffler wrote:
>> Bob Badour wrote: >> ... >> >>> The way to avoid exceptions is to treat them as compile-time errors. >> >> I take it you really mean "ONE way to avoid exceptions ...". For one >> thing, I am interested in being able to express "x join y" in advance >> of defining a header for "x" (and I would like to evaluate it as well >> if that is logically possible!).
>
> Don't forget the converse problem - there was a relation y at compile
> time that was removed before runtime; there's no way to generate a
> compile time exception for the unexceptionable, but there are not many
> ways of avoiding a runtime exception if the compile time y had defined
> attributes (was not a synonym of DEE or DUM). Obviously, you could
> reinterpret the entire program in the light of what you find at runtime,
> but then why bother with the compilation in the first place? Even
> within a single program, you could have a relation y available when it
> is first interpreted that is dropped by the time the statement
> referencing it is executed. So, some runtime exceptions are nigh-on
> unavoidable, I think.
As soon as one drops y, whatever references it must either be dropped or become unusable. Thus, as soon as one compiles a statement that references any such resource, one would get a compile-time error. Instead of generating a compile-time error when compiling some program, one would get a compile time error when one tries to invoke the program. Received on Fri Jun 30 2006 - 20:46:27 CEST