Re: I suppose the idea of classes and inheritance is



Rob Kennedy wrote:

Jamie wrote:

sorry to tell you, my R+ is normally on most of the time.
i only turn it off on finaliation of the app. but if it makes
you any happier, i included the {$R+} with no difference in
results.
my compiler is just happy with it.


Of course the compiler's happy with it. But try *running* the program.

You must take me for something i just can't amagine ?


now if you were to do that using a short string or a
array char it would then generate a range error.


No it wouldn't.

procedure TForm1.Button1Click(Sender: TObject);
Var
s:String[10];
S2:String;
I:integer;
begin
{$R+}
S2:= 'Test';
I := 11;
S[I] :='A'; // Range Check Error Like it should be.
I := 5;
S2[I] := 'A';// Does not generate Range error !
end;

Look , i am done trying to pound some common sense into.

have a good day.

--
Real Programmers Do things like this.
http://webpages.charter.net/jamie_5

.