+ bug0308 and bug0308a

This commit is contained in:
Jonas Maebe 2000-01-19 13:26:28 +00:00
parent bd9b974883
commit 291eb87a54
3 changed files with 33 additions and 1 deletions

5
bugs/bug0308.pp Normal file
View File

@ -0,0 +1,5 @@
uses bug0308a;
begin
writeln(coursedb.name(60));
end.

26
bugs/bug0308a.pp Normal file
View File

@ -0,0 +1,26 @@
unit bug0308a;
interface
type
tcourses = object
function index(cName: string): integer;
function name(cIndex: integer): string;
end;
var coursedb: tcourses;
l: longint;
implementation
function tcourses.index(cName: string): integer;
begin
index := byte(cName[0]);
end;
function tcourses.name(cIndex: integer): string;
begin
name := char(byte(cIndex));
end;
end.

View File

@ -396,4 +396,5 @@ bug0262.pp problems with virtual and overloaded methods
bug0293.pp no error with variable name = type name
bug0299.pp passing Array[0..1] of char by value to proc leads to problems
bug0305.pp Finally is not handled correctly after inputting 0
bug0307.pp "with object_type" doesn't work correctly!
bug0307.pp "with object_type" doesn't work correctly!
bug0308a.pp problem with objects that don't have VMT nor variable fields