On 20.08.2013 15:39, Xiangrong Fang wrote:
1) I didn't notice that my question are related to "modes" of fpc, i.e.
turbo-pascal/delphi/objfpc.If they are different, I would like to
know more details, and I am more interested in objfpc mode, not those
"compatibility" modes.
It has nothing t
Hi Sven,
Thank you for comment :) I am interested in a high level description of
how these concepts (virtual / reintroduce / overloading) differs and how
they affect programming, and I am currently not running into trouble, just
try to get a better understanding of the language.
I'll explain my
Am 20.08.2013 14:39 schrieb "Antonio Fortuny" :
>
>
> Le 20/08/2013 14:34, Sven Barth a écrit :
>>
>> >>
>> >> This is not same as the description in:
http://www.freepascal.org/docs-html/ref/refsu26.html
>> >>
>> >> BTW, the above documents are talking about objects, but I am using
classes, is ther
Le 20/08/2013 14:34, Sven Barth a
écrit :
>>
>> This is not same as the description in: http://www.freepascal.org/docs-html/ref/refsu26.html
>>
>> BTW, the above documents are talking about objects, but
I am using classes, is the
Am 20.08.2013 09:36 schrieb "Antonio Fortuny" :
>
>
> Le 20/08/2013 07:34, Xiangrong Fang a écrit :
>>
>> Hi Flavio,
>>
>> Your findings confirmed mine, but not telling me why? It seems that the
"virtual" keyword has no use at all! To confirm this, I just removed the
"inherited" call in TDerived,
On Tue, Aug 20, 2013 at 2:34 AM, Xiangrong Fang wrote:
> Hi Flavio,
>
> Your findings confirmed mine, but not telling me why?
I don't know why, maybe FPC used to be more strict about the use of
inherited, or the docs are simply wrong.
> It seems that the "virtual" keyword has no use at all!
It
Le 20/08/2013 07:34, Xiangrong Fang a
écrit :
Hi Flavio,
Your findings confirmed mine, but not telling me why? It
seems that the "virtual" keyword has no use at all! To
confirm this, I just removed the
On 20/08/2013 07:32, Xiangrong Fang wrote:
Thanks. Do you mean that the rules I see in the document apply to
NORMAL virtual methods, but not virtual constructors?
for all the rest, you should look for a tutorial.
it is to complex for the mailing list
__
On 20/08/2013 07:32, Xiangrong Fang wrote:
Thanks. Do you mean that the rules I see in the document apply to
NORMAL virtual methods, but not virtual constructors?
They apply to constructors too. But...
A virtual/overridden method is looked up based on the class used in code
TDerived.create; /
Thanks. Do you mean that the rules I see in the document apply to NORMAL
virtual methods, but not virtual constructors?
Also, I have a related question: it seems that to override methods in
ancestor it is required that the method has same signature, however
reintroduce will not have such limita
On 20/08/2013 02:44, Xiangrong Fang wrote:
Hi All,
I am reading this document:
http://www.freepascal.org/docs-html/ref/refsu29.html and doing an
experiment with the following code:
program project1;
{$mode objfpc}{$H+}
type
TBase = class
constructor Create; virtual;
end;
TDerived =
Hi Flavio,
Your findings confirmed mine, but not telling me why? It seems that the
"virtual" keyword has no use at all! To confirm this, I just removed the
"inherited" call in TDerived, then re-run the program with or without
"virtual/override", the result is exactly same, i.e. with c2 (declared
On Mon, Aug 19, 2013 at 10:44 PM, Xiangrong Fang wrote:
> Hi All,
>
> I am reading this document:
> http://www.freepascal.org/docs-html/ref/refsu29.html and doing an
> experiment with the following code:
>
> program project1;
> {$mode objfpc}{$H+}
> type
> TBase = class
> constructor Creat
13 matches
Mail list logo