* new negative test cases for interface to TGuid/Shortstring assign

git-svn-id: trunk@12724 -
This commit is contained in:
ivost 2009-02-08 21:24:28 +00:00
parent 549f1ecc1b
commit b2235eb873
5 changed files with 70 additions and 0 deletions

4
.gitattributes vendored
View File

@ -6663,6 +6663,10 @@ tests/tbf/tb0212.pp svneol=native#text/plain
tests/tbf/tb0213.pp svneol=native#text/plain
tests/tbf/tb0214.pp svneol=native#text/plain
tests/tbf/tb0215.pp svneol=native#text/plain
tests/tbf/tb0215a.pp svneol=native#text/plain
tests/tbf/tb0215b.pp svneol=native#text/plain
tests/tbf/tb0215c.pp svneol=native#text/plain
tests/tbf/tb0215d.pp svneol=native#text/plain
tests/tbf/ub0115.pp svneol=native#text/plain
tests/tbf/ub0149.pp svneol=native#text/plain
tests/tbf/ub0158a.pp svneol=native#text/plain

16
tests/tbf/tb0215a.pp Normal file
View File

@ -0,0 +1,16 @@
{ %FAIL }
// it's not allowed to assign a corbainterface to TGuid
{$mode objfpc}
{$INTERFACES CORBA}
type
ITest = interface
['{0374223C-E460-4CC2-ABFD-7723AAB80CFE}']
end;
const
Test_IID: TGuid = ITest;
begin
end.

18
tests/tbf/tb0215b.pp Normal file
View File

@ -0,0 +1,18 @@
{ %FAIL }
// it's not allowed to assign a corbainterface to TGuid
{$mode objfpc}
{$INTERFACES CORBA}
type
ITest = interface
['{0374223C-E460-4CC2-ABFD-7723AAB80CFE}']
end;
procedure foo(iid: tguid);
begin
end;
begin
foo(ITest);
end.

16
tests/tbf/tb0215c.pp Normal file
View File

@ -0,0 +1,16 @@
{ %FAIL }
// it's not allowed to assign a corbainterface to TGuid
{$mode objfpc}
{$INTERFACES COM}
type
ITest = interface
['{0374223C-E460-4CC2-ABFD-7723AAB80CFE}']
end;
const
Test_IID: Shortstring = ITest;
begin
end.

16
tests/tbf/tb0215d.pp Normal file
View File

@ -0,0 +1,16 @@
{ %FAIL }
// it's not allowed to assign a corbainterface to TGuid
{$mode objfpc}
{$INTERFACES COM}
type
ITest = interface
['{0374223C-E460-4CC2-ABFD-7723AAB80CFE}']
end;
const
Test_IID: Shortstring = ITest;
begin
end.