[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Axiom-developer] RE: Cast = pretend in Spad/Aldor?

From: C Y
Subject: Re: [Axiom-developer] RE: Cast = pretend in Spad/Aldor?
Date: Tue, 22 Nov 2005 14:12:41 -0800 (PST)

--- root <address@hidden> wrote:

> ultimately i think the issue comes down to this: i'm a 
> primitivist by nature and expect programmers, like myself, to
> know EXACTLY what the machine will execute when i use high
> level languages like spad, lisp, or haskell. (and to send 
> email by tapping on the correct wire pair in an ethernet cable
> with a battery.)

While I agree this is sometimes necessary in practice, isn't the whole
idea of high level languages to avoid this necessity?

> i "understand clearly what is involved in the abstraction of
> types in high level languages" as i've implemented several 
> languages, 4 of which were sold commercially and i've been 
> involved in endless language "feature" discussions.
> your approach to programming "from the other end of the 
> telescope" tends to view the machine as a distant abstraction
> and expect programming languages to properly support their
> abstractions in all their various nuances. thus, you expect
> that
>    type-thing :=               other-type-thing
>    type-thing := (cast)        other-type-thing
>    type-thing := (coerce)      other-type-thing
>    type-thing := thing pretend other-type-thing
> to "do the right thing" and i tend to run (disassemble) to
> figure out what it ACTUALLY does on the machine.

I thought this might be a good use for unit testing actually - defined
the "right thing" on a per-abstraction basis and verify that it
actually does happen on a per-machine basis?

> Axiom DOES support strong static typing but (at least in my
> view) it isn't a closed semantics language so sometimes you
> have to know the internals. in your view the primitive
> domains would export operations that hide the implementation,
> fully support the abstractions and have closed semantics.

At least at the Spad/Aldor level, isn't this desirable?  Or would
BNatural be the logical level for "bullet-proofing" in this fashion?
> ultimately you want to appeal to the documentation to see what
> a language construct means. i kneel before the altar of the 
> machine and see what it does.

I always thought what made the most sense was to clearly define the
behaviors an abstraction needs to function properly as part of the
documentation, and have a way in the program to test that those
assumptions actually ARE valid.  That gives you not just assumption of
valid abstractions but verified valid abstractions, and allows one to
work at the abstracted level with confidence.

I suspect I'm missing something though - typing related issues are way
beyond me :-/.

> ps. i liked programming in high school. the wang mini with the
> hand-punched "toaster" card reader kicked ass. :-)

Heh - I always like the idea of punch cards.  They seem a lot more
durable than any of our electronic storage methods, even if their data
density per kilogram is a tad low.


Yahoo! FareChase: Search multiple travel sites in one click.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]