On 2017-10-24 18:55, Diego Sardina wrote:
On Monday, October 23, 2017 at 11:57:15 PM UTC+2, [email protected] wrote:
Are you serious?
Yes, what is the type of "abc"?
I think of a string literal as having type `string'. It's like the
opposite of BYTE in the sense that there are only constants of this type
but no variables.
What operations are defined for it?
We can't tell simply by reading the language report. In my book, except
being assigned to character array variables, string literals must be
allowed to be passed as actual value parameters and be compared with
character array variables. This is how strings work in Oberon-2.
Anything less makes the language artificially inconvenient to use and is
more in line with "Make it as simple ass possible and then simpler".
If you know nothing about it, how do you put something like this in an expression?
The same argument can be applied to NIL. It is never mentioned
explicitly that NIL can be compared with pointer or procedure variables.
-- August
--- SoupGate-Win32 v1.05
* Origin: fsxNet Usenet Gateway (21:1/5)