Sergei
> > Is there a way to prevent the D5 link from
eliminating
> > unreferenced methods/properties?
>
> I'm not sure if I got your question right, but putting a blank comment
> within a method prevents it from being removed at compilation time.
>
> procedure TForm1.FormClick(Sender: TObject);
> begin
> //
> end;
> > unreferenced methods/properties?
>
> I'm not sure if I got your question right, but putting a blank comment
> within a method prevents it from being removed at compilation time.
>
> procedure TForm1.FormClick(Sender: TObject);
> begin
> //
> end;
I didn't really make the question
clear.
Here is the situation i'm talking
about:
class Foo;
//...
private
function getSomething: string;
public
property Something:string read getSomething;
function getSomething: string;
public
property Something:string read getSomething;
end;
//...
implementation
procedure myClass.getSomething:string;
begin
result:=doSomeStuff(p1,2);
end;
if I write a program that uses the above "class"
but
never reference the "Something" property anywhere,
the
linker will remove getsomething() from the EXE and
while debugging it will not be possible to
evaluate
aFoo.Something
in (say) a watch because the debugger will report
that the property
was removed at link time.
Sometimes it might be useful during debugging to be
able
to examine properties even if they are unused
elsewhere.
-ns