Something to be aware of is that the default value of this switch has
changed in Delphi 6.
>From the D6 help:
"The default setting for $WRITEABLECONST ($J) compiler directive has changed
from ON to OFF. This means that you must explicitly turn this compiler flag
on before you can write to typed c
m: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
> Behalf Of John Christenhusz
> Sent: Monday, 12 November 2001 12:30
> To: Multiple recipients of list delphi
> Subject: [DUG]: Const
>
>
> Hi all,
>
> Can anybody tell me the difference between the following two declarations
;
Regards,
Dennis.
> -Original Message-
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, 13 November 2001 01:30
> To: Multiple recipients of list delphi
> Subject: [DUG]: Const
>
>
> Hi all,
>
> Can anybody tell me the difference between th
IL PROTECTED]>
Sent: Monday, November 12, 2001 12:29 PM
Subject: [DUG]: Const
> Hi all,
>
> Can anybody tell me the difference between the following two declarations
> and why you want to use the first one. The second one seems to use less
> memory!
>
>
> const
>
OTECTED]>
To: "Multiple recipients of list delphi" <[EMAIL PROTECTED]>
Sent: Monday, November 12, 2001 12:32 PM
Subject: RE: [DUG]: Const
> Just a guess, but the second one probably uses shortstring, rather than
> string.
>
> Stacey
>
> > -Original Me
Just a guess, but the second one probably uses shortstring, rather than
string.
Stacey
> -Original Message-
> From: John Christenhusz [mailto:[EMAIL PROTECTED]]
> Sent: Monday, 12 November 2001 12:30 p.m.
> To: Multiple recipients of list delphi
> Subject: [DUG]: Const
Hi all,
Can anybody tell me the difference between the following two declarations
and why you want to use the first one. The second one seems to use less
memory!
const
sName : string = 'This is a test';
and
const
sName = 'This is a test';
TIA
John.