Re: ADA Popularity Discussion Request

From: Georg Bauhaus (sb463ba_at_l1-hrz.uni-duisburg.de)
Date: 09/08/04


Date: Wed, 8 Sep 2004 10:40:47 +0000 (UTC)

jayessay <nospam@foo.com> wrote:
: Georg Bauhaus <sb463ba@l1-hrz.uni-duisburg.de> writes:

:> Sure it is insufficient. But it adds value by removing the need to
:> test what the compiler has already found out. How about typos?
:
: True. But since this is determined anyway as part of incremental
: development it doesn't actually save anything in practice. Typos are
: a good example.
:
:
:> Here is a fake:
:>
:> (defun next (n) (1 + n))
:> (defun hext (n) (1 + (mod n 16)))
:
: Let's see this in practice:

[lengthy testing snipped]

Do you see what I mean? ;-) ;-) ;-) Wouldn't have happend with
proper typing and static type checks, see below.

: What you are saying is, range types (as in Ada) could have caught
: this. True, but they would not have caught it quicker (or even as
: quick) as this did.

No, I'm saying that this error can occur in an executing piece
of program if and only if the compiler allows me to mix
operations of an integer type and operations a modular type
without notice.
  Things like this don't happen if you get the types right at
compiletime. Similarly, physical units can be checked at compile
time using C++ templates. Is there a set of Lisp macros that
guarantees unit safe computations before a program runs?

: Also, they wouldn't have caught the error in hext
: until you ran it anyway.

Not true as explained above.

-- Georg



Relevant Pages

  • Names.Add Bug
    ... However, in practice, if you try to do this, the compiler generates an error ... saying "The expression does not produce a value". ... Clearly either the help file or the code is in error and if consistency with ...
    (microsoft.public.office.developer.web.components)
  • Re: Error checking with execlp()
    ... |>> I'm not saying that it is incorrect to include it. ... is to quash a compiler warning, usually about a possibly uninitialized variable ... enough to know that no path could be followed that would not assigne it. ... was a way to assert to the compiler that a variable really has been assigned ...
    (comp.unix.programmer)
  • Re: [Lit.] Buffer overruns
    ... > don't even have to bother swapping out the compiler. ... It does not take an adversary to create a security hole, ... And those errors abound. ... That is a far cry from saying that it is secure and can be ...
    (sci.crypt)
  • Re: C# Nullable types
    ... string x = null; ... compiler that by using the language specific word called "null". ... so we are given a keyword to state our intentions as the ... I am saying that I don't want x to have any value and I am "ok" with that. ...
    (microsoft.public.dotnet.framework)
  • Re: Flexible arrays - v confused
    ... and that includes using a C++ compiler (which has stricter type ... Or are you saying that anything superfluous, ... posts, you've known my counter argument before this post. ...
    (comp.lang.c)