Micha Nelissen wrote:
Marc Weustink wrote:
the following app is valid:
program a;
{$mode objfpc}{$h+}
var
p: PChar;
s: String;
begin
p := 'abcdef';
s := p;
end.
An assignment is not necessarily the same as a typecast, as far as I
know. They could be handled by different pieces of compiler code and
have different semantics.
the s := String(p) line was not in the example but was in the assembler.
In this case String(p) is behaving more like a functiuon than a cast.
Marc
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives