Program logic bugs vs input/environmental errors
eles via Digitalmars-d
digitalmars-d at puremagic.com
Fri Oct 3 21:36:48 PDT 2014
On Saturday, 4 October 2014 at 04:26:45 UTC, ketmar via
Digitalmars-d wrote:
> On Sat, 04 Oct 2014 04:10:49 +0000
> eles via Digitalmars-d <digitalmars-d at puremagic.com> wrote:
>
>> >> Where's the contradiction? The compilers state hasn't been
>> >> corrupted just because it encounters errors in the text
>> >> file.
>> > but compiler is in unknown state.
>> It's not. It just detected that another system would enter in
>> an unknown state if built. The compiler is like the engineer
>> that examines the design of a project and discovers an error
>> on it, so it refuses to build the product. Is the engineer in
>> an unknown state?
> sorry. i meant that compiler WILL be in unknown state if it will
> continute to processing invalid source. that's why it should
> stop right
> after the first error.
No. It might produce an invalid product. Just like a real
engineer could produce a flawed product on the basis of wrong
designs.
Yes, you might reach a state where you are no longer be able to
continue because physically impossible. "Build a round square".
Both the engineer and the compiler will bark when they see this.
>> Guessing might not be good, but it is nice effort to do. Do
>> you really miss the super-cryptic C (let's not even talk about
>> C++) error messages that you sometimes receive?
> yes. DMD attempts to 'guess' what identifier i mistyped drives
> me
> crazy. just shut up and stop after "unknown identifier", you
> robot,
> don't try to show me your artificial idiocity!
Could we add a flag to the compiler for that?
-cassandramode=[yes/no/whatever]
Joke :)
Anyway, the Cassandra name for the compiler is just perfect: it
might be right, but you won't believe!
More information about the Digitalmars-d
mailing list