[Aldor-l] Compiling setup

Gabriel Dos Reis gdr at integrable-solutions.net
Sat Aug 12 20:15:52 EDT 2006


Ralf Hemmecke <ralf at hemmecke.de> writes:

| > | If the compiler sees something like
| > | |    "blah"
| > | | in general it is even impossible to guess the type of that thing.
| 
| > To my eyes, that is a literal string.
| 
| That seems to be true, but what does "literal string" actually mean?

s/literal string/string literal/

The meaning is whatever the Aldor definition says it is.  See section
5.2, page 38.

| It is definitely not something of the libaldor type String (my base
| library might be something else where String does not even exist). And
| as you saw from the program I gave, it could mean the Integer 4.

I appreciate all that.  The issue under discussion, is what should be
the proper translation of 

    a : String == "vlndoffmnelcfeeqmeejfoie";

into C.

| I guess the Aldor type Literal is probably the closest we can get.

The way literals are treated in Aldor is not very different from what
Haskell does for integer literals for example.  If you're not happy
with the appearant type "string literal", you can view it as having
type (borrowing notation from Haskell):

    "blah" : forall a. () -> a

-- Gaby



More information about the Aldor-l mailing list