[fpc-pascal] bug or feature?
Florian Klämpfl
florian at freepascal.org
Sun Feb 13 10:39:54 CET 2022
Am 13.02.2022 um 10:25 schrieb Sven Barth via fpc-pascal:
> Michael Van Canneyt via fpc-pascal <fpc-pascal at lists.freepascal.org <mailto:fpc-pascal at lists.freepascal.org>> schrieb am
> So., 13. Feb. 2022, 09:47:
>
>
>
> On Sun, 13 Feb 2022, Mattias Gaertner via fpc-pascal wrote:
>
> > On Sat, 12 Feb 2022 12:14:14 +0100 (CET)
> > Michael Van Canneyt via fpc-pascal <fpc-pascal at lists.freepascal.org <mailto:fpc-pascal at lists.freepascal.org>>
> > wrote:
> >
> >> On Sat, 12 Feb 2022, Mattias Gaertner via fpc-pascal wrote:
> >>
> >> > Hi,
> >> >
> >> > This can't be right, can it?
> >> >
> >> > type
> >> > TBird = class
> >> > procedure Fly;
> >> > end;
> >> > TEagle = TBird; // alias
> >> >
> >> > procedure TEagle.Fly;
> >> > begin
> >> > end;
> >>
> >> Personally, I would not allow this.
> >> But Delphi compiles and runs it...
> >
> > ... and Delphi's class completion no longer works in the unit giving a
> > useless error "expected ';' but '.' found". So it is one of those
> > Delphi "features" compiling but not usable.
>
> I'm all for forbidding this in objfpc mode.
>
>
> Then file a bug report for it. Cause it's definitely going to be one of the low priority things cause it's going to be
> annoying to fix...
I thought (famous last words), checking the typesyms of the tobjectdef would be enough but who knows what else will bit :)
More information about the fpc-pascal
mailing list