diff --git a/tests/webtbs/tw2724.pp b/tests/webtbs/tw2724.pp new file mode 100644 index 0000000000..009d6761d7 --- /dev/null +++ b/tests/webtbs/tw2724.pp @@ -0,0 +1,20 @@ +{ Source provided for Free Pascal Bug Report 2724 } +{ Submitted by "marco" on 2003-10-08 } +{ e-mail: } + +{$Mode delphi} +type + TBitSet = class(TBits) + constructor Create(aSize: integer); + end; + +{ TBitSet } + +constructor TBitSet.Create(aSize: integer); +begin + inherited Create; + Size := aSize; +end; + +begin +end. \ No newline at end of file diff --git a/tests/webtbs/tw2725.pp b/tests/webtbs/tw2725.pp new file mode 100644 index 0000000000..d479ba15c3 --- /dev/null +++ b/tests/webtbs/tw2725.pp @@ -0,0 +1,23 @@ +{ Source provided for Free Pascal Bug Report 2725 } +{ Submitted by "marco" on 2003-10-08 } +{ e-mail: } + +{$Mode delphi} + +Uses Classes; + +type + TBitSet = class(TBits) + constructor Create(aSize: integer); + end; + +{ TBitSet } + +constructor TBitSet.Create(aSize: integer); +begin + inherited Create; + Size := aSize; +end; + +begin +end. \ No newline at end of file diff --git a/tests/webtbs/tw2727.pp b/tests/webtbs/tw2727.pp new file mode 100644 index 0000000000..d1b30351d2 --- /dev/null +++ b/tests/webtbs/tw2727.pp @@ -0,0 +1,34 @@ +{ Source provided for Free Pascal Bug Report 2727 } +{ Submitted by "marco (the gory bugs department)" on 2003-10-08 } +{ e-mail: } + +{$mode delphi} + + +type + IPersistenceCapable = interface; + + TPersistenceCapable = class(TInterfacedObject, IPersistenceCapable) + function nonsense:boolean; + end; + + IPersistenceCapable = interface + ['{A7F3DA50-93BF-4EAF-B40C-8F5020E5D890}'] + function GetSelf: TObject; + property Self: TObject read GetSelf; + end; + + +function TPersistenceCapable.nonsense:boolean; +{this works fine if it isn't a method....} + +var + lSource: IPersistenceCapable; + +begin + result:=(lSource.Self is TPersistenceCapable) +end; + + +begin +end. diff --git a/tests/webtbs/tw2728.pp b/tests/webtbs/tw2728.pp new file mode 100644 index 0000000000..ef32fc40cf --- /dev/null +++ b/tests/webtbs/tw2728.pp @@ -0,0 +1,17 @@ +{ Source provided for Free Pascal Bug Report 2728 } +{ Submitted by "marco (the gory bugs department)" on 2003-10-09 } +{ e-mail: } +{$mode delphi} +type baseclass = class end; + tbaseclass= class of baseclass; + +function test (c : tbaseclass):longint; + +var o :tobject; + +begin + o:=tobject(c); // illegal type conversion here +end; + +begin +end. diff --git a/tests/webtbs/tw2729.pp b/tests/webtbs/tw2729.pp new file mode 100644 index 0000000000..b949dd9e75 --- /dev/null +++ b/tests/webtbs/tw2729.pp @@ -0,0 +1,17 @@ +{ Source provided for Free Pascal Bug Report 2729 } +{ Submitted by "marco (the gory bugs department)" on 2003-10-09 } +{ e-mail: } +{$mode delphi} + +type tbla= class(tobject) + class function bla:tbla; + end; + +class function tbla.bla:tbla; + +begin + result:=Create; +end; + +begin +end.