mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-16 01:39:27 +02:00
* changes to compile it with Delphi 4.0
This commit is contained in:
parent
001fe80149
commit
78d13ec796
@ -78,7 +78,7 @@ unit ag386bin;
|
||||
var
|
||||
ofs,
|
||||
nidx,nother,i,line,j : longint;
|
||||
code : word;
|
||||
code : integer;
|
||||
hp : pchar;
|
||||
reloc : boolean;
|
||||
sec : tsection;
|
||||
@ -662,7 +662,10 @@ unit ag386bin;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.1 1999-05-01 13:23:57 peter
|
||||
Revision 1.2 1999-05-04 21:44:30 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.1 1999/05/01 13:23:57 peter
|
||||
* merged nasm compiler
|
||||
* old asm moved to oldasm/
|
||||
|
||||
|
@ -99,11 +99,15 @@ unit ag386int;
|
||||
c : comp;
|
||||
dd : pdouble;
|
||||
begin
|
||||
{$ifdef TP}
|
||||
{$ifdef TP}
|
||||
c:=d;
|
||||
{$else}
|
||||
{$else TP}
|
||||
{$ifdef Delphi}
|
||||
c:=d;
|
||||
{$else Delphi}
|
||||
c:=comp(d);
|
||||
{$endif}
|
||||
{$endif Delphi}
|
||||
{$endif TP}
|
||||
dd:=pdouble(@c); { this makes a bitwise copy of c into a double }
|
||||
comp2str:=double2str(dd^);
|
||||
end;
|
||||
@ -769,7 +773,10 @@ ait_stab_function_name : ;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.35 1999-05-02 22:41:49 peter
|
||||
Revision 1.36 1999-05-04 21:44:31 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.35 1999/05/02 22:41:49 peter
|
||||
* moved section names to systems
|
||||
* fixed nasm,intel writer
|
||||
|
||||
|
@ -99,11 +99,15 @@ unit ag386nsm;
|
||||
c : comp;
|
||||
dd : pdouble;
|
||||
begin
|
||||
{$ifdef TP}
|
||||
{$ifdef TP}
|
||||
c:=d;
|
||||
{$else}
|
||||
{$else TP}
|
||||
{$ifdef Delphi}
|
||||
c:=d;
|
||||
{$else Delphi}
|
||||
c:=comp(d);
|
||||
{$endif}
|
||||
{$endif Delphi}
|
||||
{$endif TP}
|
||||
dd:=pdouble(@c); { this makes a bitwise copy of c into a double }
|
||||
comp2str:=double2str(dd^);
|
||||
end;
|
||||
@ -733,7 +737,10 @@ ait_stab_function_name : ;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.30 1999-05-02 22:41:50 peter
|
||||
Revision 1.31 1999-05-04 21:44:32 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.30 1999/05/02 22:41:50 peter
|
||||
* moved section names to systems
|
||||
* fixed nasm,intel writer
|
||||
|
||||
|
@ -29,6 +29,9 @@ interface
|
||||
{$endif}
|
||||
|
||||
uses
|
||||
{$ifdef Delphi}
|
||||
dmisc,
|
||||
{$endif Delphi}
|
||||
dos,cobjects,globtype,globals,aasm;
|
||||
|
||||
const
|
||||
@ -545,7 +548,10 @@ end;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.44 1999-05-02 23:28:42 peter
|
||||
Revision 1.45 1999-05-04 21:44:33 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.44 1999/05/02 23:28:42 peter
|
||||
* don't include ag386bin for oldasm
|
||||
|
||||
Revision 1.43 1999/05/02 22:41:51 peter
|
||||
|
@ -659,8 +659,11 @@ implementation
|
||||
var
|
||||
lv,hv,min_label,max_label,labels : longint;
|
||||
max_linear_list : longint;
|
||||
{$ifdef Delphi}
|
||||
dist : longword;
|
||||
{$else Delphi}
|
||||
dist : dword;
|
||||
|
||||
{$endif Delphi}
|
||||
begin
|
||||
getlabel(endlabel);
|
||||
getlabel(elselabel);
|
||||
@ -741,10 +744,17 @@ implementation
|
||||
|
||||
if (min_label<0) and (max_label>0) then
|
||||
begin
|
||||
{$ifdef Delphi}
|
||||
if min_label=$80000000 then
|
||||
dist:=longword(max_label)+longword($80000000)
|
||||
else
|
||||
dist:=longword(max_label)+longword(-min_label)
|
||||
{$else Delphi}
|
||||
if min_label=$80000000 then
|
||||
dist:=dword(max_label)+dword($80000000)
|
||||
else
|
||||
dist:=dword(max_label)+dword(-min_label)
|
||||
{$endif Delphi}
|
||||
end
|
||||
else
|
||||
dist:=max_label-min_label;
|
||||
@ -824,7 +834,10 @@ implementation
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.28 1999-05-01 13:24:15 peter
|
||||
Revision 1.29 1999-05-04 21:44:34 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.28 1999/05/01 13:24:15 peter
|
||||
* merged nasm compiler
|
||||
* old asm moved to oldasm/
|
||||
|
||||
|
@ -154,13 +154,17 @@ begin
|
||||
{ Status info?, Called every line }
|
||||
if ((status.verbosity and V_Status)<>0) then
|
||||
begin
|
||||
{$ifndef Delphi}
|
||||
if (status.compiledlines=1) then
|
||||
WriteLn(memavail shr 10,' Kb Free');
|
||||
{$endif Delphi}
|
||||
if (status.currentline>0) and (status.currentline mod 100=0) then
|
||||
{$ifdef FPC}
|
||||
WriteLn(status.currentline,' ',memavail shr 10,'/',system.heapsize shr 10,' Kb Free');
|
||||
{$else}
|
||||
{$ifndef Delphi}
|
||||
WriteLn(status.currentline,' ',memavail shr 10,' Kb Free');
|
||||
{$endif Delphi}
|
||||
{$endif}
|
||||
end
|
||||
end;
|
||||
@ -261,7 +265,10 @@ end;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.15 1999-01-15 12:27:23 peter
|
||||
Revision 1.16 1999-05-04 21:44:38 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.15 1999/01/15 12:27:23 peter
|
||||
* removed path from output, was there only for debugging
|
||||
|
||||
Revision 1.14 1999/01/14 21:47:09 peter
|
||||
|
@ -92,6 +92,9 @@ uses
|
||||
{$ifdef BrowserCol}
|
||||
browcol,
|
||||
{$endif BrowserCol}
|
||||
{$ifdef Delphi}
|
||||
dmisc,
|
||||
{$endif Delphi}
|
||||
dos,verbose,comphook,systems,
|
||||
globals,options,parser,symtable,link,import,export;
|
||||
|
||||
@ -266,7 +269,10 @@ end;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.20 1999-04-21 09:43:33 peter
|
||||
Revision 1.21 1999-05-04 21:44:39 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.20 1999/04/21 09:43:33 peter
|
||||
* storenumber works
|
||||
* fixed some typos in double_checksum
|
||||
+ incompatible types type1 and type2 message (with storenumber)
|
||||
|
@ -30,6 +30,9 @@ procedure CompileResourceFiles;
|
||||
implementation
|
||||
|
||||
uses
|
||||
{$ifdef Delphi}
|
||||
dmisc,
|
||||
{$endif Delphi}
|
||||
Dos,
|
||||
Systems,Globtype,Globals,Verbose,Files,
|
||||
Script;
|
||||
@ -53,7 +56,11 @@ var
|
||||
utilsdirectory,resfound);
|
||||
end
|
||||
else
|
||||
{$ifdef Delphi}
|
||||
respath:=Search(target_res.resbin+source_os.exeext,'.;'+exepath+';'+dmisc.getenv('PATH'),resfound);
|
||||
{$else Delphi}
|
||||
respath:=Search(target_res.resbin+source_os.exeext,'.;'+exepath+';'+dos.getenv('PATH'),resfound);
|
||||
{$endif Delphi}
|
||||
resbin:=respath+target_res.resbin+source_os.exeext;
|
||||
if (not resfound) and not(cs_link_extern in aktglobalswitches) then
|
||||
begin
|
||||
@ -103,7 +110,10 @@ end;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.3 1999-01-06 14:38:09 michael
|
||||
Revision 1.4 1999-05-04 21:44:40 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.3 1999/01/06 14:38:09 michael
|
||||
+ Fixed wrong unit name.
|
||||
|
||||
Revision 1.2 1999/01/06 12:56:01 peter
|
||||
|
@ -328,7 +328,7 @@ var
|
||||
SI: TStartupInfo;
|
||||
PI: TProcessInformation;
|
||||
Proc : THandle;
|
||||
l : Longint;
|
||||
l : DWord;
|
||||
AppPath,
|
||||
AppParam : array[0..255] of char;
|
||||
begin
|
||||
@ -351,7 +351,7 @@ begin
|
||||
if WaitForSingleObject(Proc, Infinite) <> $ffffffff then
|
||||
GetExitCodeProcess(Proc,l)
|
||||
else
|
||||
l:=-1;
|
||||
l:=$ffffffff;
|
||||
CloseHandle(Proc);
|
||||
LastDosExitCode:=l;
|
||||
end;
|
||||
@ -395,7 +395,7 @@ function diskfree(drive : byte) : longint;
|
||||
var
|
||||
disk : array[1..4] of char;
|
||||
secs,bytes,
|
||||
free,total : longint;
|
||||
free,total : DWord;
|
||||
begin
|
||||
if drive=0 then
|
||||
begin
|
||||
@ -420,7 +420,7 @@ function disksize(drive : byte) : longint;
|
||||
var
|
||||
disk : array[1..4] of char;
|
||||
secs,bytes,
|
||||
free,total : longint;
|
||||
free,total : DWord;
|
||||
begin
|
||||
if drive=0 then
|
||||
begin
|
||||
@ -848,7 +848,10 @@ End;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.1 1998-09-18 16:03:38 florian
|
||||
Revision 1.2 1999-05-04 21:44:41 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.1 1998/09/18 16:03:38 florian
|
||||
* some changes to compile with Delphi
|
||||
|
||||
}
|
||||
|
@ -221,6 +221,9 @@ unit files;
|
||||
implementation
|
||||
|
||||
uses
|
||||
{$ifdef Delphi}
|
||||
dmisc,
|
||||
{$endif Delphi}
|
||||
dos,verbose,systems,
|
||||
symtable,scanner;
|
||||
|
||||
@ -1191,7 +1194,10 @@ uses
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.93 1999-04-26 13:31:29 peter
|
||||
Revision 1.94 1999-05-04 21:44:42 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.93 1999/04/26 13:31:29 peter
|
||||
* release storenumber,double_checksum
|
||||
|
||||
Revision 1.92 1999/04/25 15:08:36 peter
|
||||
|
@ -33,6 +33,10 @@ unit globals;
|
||||
{$ifdef TP}
|
||||
objects,
|
||||
{$endif}
|
||||
{$ifdef Delphi4}
|
||||
dmisc,
|
||||
sysutils,
|
||||
{$endif}
|
||||
{$ifdef linux}
|
||||
linux,
|
||||
{$endif}
|
||||
@ -655,7 +659,11 @@ unit globals;
|
||||
var
|
||||
hour,min,sec,hsec : word;
|
||||
begin
|
||||
{$ifdef delphi}
|
||||
dmisc.gettime(hour,min,sec,hsec);
|
||||
{$else delphi}
|
||||
dos.gettime(hour,min,sec,hsec);
|
||||
{$endif delphi}
|
||||
gettimestr:=L0(Hour)+':'+L0(min)+':'+L0(sec);
|
||||
end;
|
||||
|
||||
@ -667,7 +675,11 @@ unit globals;
|
||||
var
|
||||
Year,Month,Day,Wday : Word;
|
||||
begin
|
||||
{$ifdef delphi}
|
||||
dmisc.getdate(year,month,day,wday);
|
||||
{$else}
|
||||
dos.getdate(year,month,day,wday);
|
||||
{$endif}
|
||||
getdatestr:=L0(Year)+'/'+L0(Month)+'/'+L0(Day);
|
||||
end;
|
||||
|
||||
@ -728,7 +740,14 @@ unit globals;
|
||||
Begin
|
||||
End;
|
||||
{$endif not FPC}
|
||||
{$ifdef delphi}
|
||||
Function FileExists ( Const F : String) : Boolean;
|
||||
|
||||
begin
|
||||
FileExists:=sysutils.FileExists(f);
|
||||
end;
|
||||
|
||||
{$else}
|
||||
Function FileExists ( Const F : String) : Boolean;
|
||||
Var
|
||||
{$ifdef linux}
|
||||
@ -745,6 +764,7 @@ unit globals;
|
||||
findclose(Info);
|
||||
{$endif}
|
||||
end;
|
||||
{$endif}
|
||||
|
||||
|
||||
Function RemoveFile(const f:string):boolean;
|
||||
@ -1014,7 +1034,11 @@ unit globals;
|
||||
if FStat (F,Info) then
|
||||
L:=info.mtime;
|
||||
{$else}
|
||||
{$ifdef delphi}
|
||||
dmisc.FindFirst (F,archive+readonly+hidden,info);
|
||||
{$else delphi}
|
||||
FindFirst (F,archive+readonly+hidden,info);
|
||||
{$endif delphi}
|
||||
if DosError=0 then
|
||||
l:=info.time;
|
||||
{$ifdef Linux}
|
||||
@ -1057,7 +1081,11 @@ unit globals;
|
||||
function FindExe(bin:string;var found:boolean):string;
|
||||
begin
|
||||
bin:=FixFileName(bin)+source_os.exeext;
|
||||
{$ifdef delphi}
|
||||
FindExe:=Search(bin,'.;'+exepath+';'+dmisc.getenv('PATH'),found)+bin;
|
||||
{$else delphi}
|
||||
FindExe:=Search(bin,'.;'+exepath+';'+dos.getenv('PATH'),found)+bin;
|
||||
{$endif delphi}
|
||||
end;
|
||||
|
||||
procedure abstract;
|
||||
@ -1075,7 +1103,11 @@ unit globals;
|
||||
hs1 : namestr;
|
||||
hs2 : extstr;
|
||||
begin
|
||||
{$ifdef delphi}
|
||||
exepath:=dmisc.getenv('PPC_EXEC_PATH');
|
||||
{$else delphi}
|
||||
exepath:=dos.getenv('PPC_EXEC_PATH');
|
||||
{$endif delphi}
|
||||
if exepath='' then
|
||||
fsplit(FixFileName(paramstr(0)),exepath,hs1,hs2);
|
||||
{$ifdef linux}
|
||||
@ -1159,7 +1191,10 @@ begin
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.4 1999-04-26 13:31:32 peter
|
||||
Revision 1.5 1999-05-04 21:44:43 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.4 1999/04/26 13:31:32 peter
|
||||
* release storenumber,double_checksum
|
||||
|
||||
Revision 1.3 1999/04/21 14:12:55 peter
|
||||
|
@ -65,6 +65,9 @@ Var
|
||||
Implementation
|
||||
|
||||
uses
|
||||
{$ifdef Delphi}
|
||||
dmisc,
|
||||
{$endif Delphi}
|
||||
globtype,systems,
|
||||
script,globals,verbose
|
||||
{$ifdef i386}
|
||||
@ -637,7 +640,10 @@ end;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.52 1999-05-03 21:30:30 peter
|
||||
Revision 1.53 1999-05-04 21:44:44 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.52 1999/05/03 21:30:30 peter
|
||||
+ glibc 2.1
|
||||
|
||||
Revision 1.51 1999/04/28 23:42:33 pierre
|
||||
|
@ -1,4 +1,4 @@
|
||||
ppc386 -OG2p2 -Ch8000000 -dI386 -dGDB -dBROWSERLOG -a -Sg pp.pas %1 %2 %3 %4 %5 %6 %7 %8 %9
|
||||
ppc386 -Ch8000000 -dI386 -dGDB -dBROWSERLOG -a -Sg pp.pas %1 %2 %3 %4 %5 %6 %7 %8 %9
|
||||
if errorlevel 0 goto success
|
||||
goto failed
|
||||
:success
|
||||
|
@ -1,4 +1,8 @@
|
||||
{$ifdef Delphi}
|
||||
const msgtxt : array[0..00103] of string[240]=(
|
||||
{$else}
|
||||
const msgtxt : array[0..00103,1..240] of char=(
|
||||
{$endif}
|
||||
'T_Compiler: $1'#000+
|
||||
'D_Source OS: $1'#000+
|
||||
'I_Target OS: $1'#000+
|
||||
@ -537,7 +541,7 @@ const msgtxt : array[0..00103,1..240] of char=(
|
||||
'Compiler Date : $FPCDATE'#000+
|
||||
'Compiler Target: $FPCTARGET'#000+
|
||||
#000+
|
||||
'This program comes under the GNU General Public Licence'#000,+
|
||||
'This program comes under the GNU General Public Licence'#000,
|
||||
'For more information read COPYING.FPC'#000+
|
||||
#000+
|
||||
'Report bugs,suggestions etc to:'#000+
|
||||
|
@ -28,6 +28,9 @@ unit og386;
|
||||
|
||||
interface
|
||||
uses
|
||||
{$ifdef Delphi}
|
||||
dmisc,
|
||||
{$endif Delphi}
|
||||
dos,
|
||||
owbase,owar,
|
||||
systems,i386base,aasm;
|
||||
@ -236,7 +239,10 @@ unit og386;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.2 1999-05-02 22:41:54 peter
|
||||
Revision 1.3 1999-05-04 21:44:50 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.2 1999/05/02 22:41:54 peter
|
||||
* moved section names to systems
|
||||
* fixed nasm,intel writer
|
||||
|
||||
|
@ -47,7 +47,11 @@ type
|
||||
|
||||
implementation
|
||||
|
||||
uses globtype,dos,strings,globals,link,files;
|
||||
uses
|
||||
{$ifdef Delphi}
|
||||
dmisc,
|
||||
{$endif Delphi}
|
||||
globtype,dos,strings,globals,link,files;
|
||||
|
||||
const profile_flag:boolean=false;
|
||||
|
||||
@ -329,7 +333,10 @@ end.
|
||||
|
||||
{
|
||||
$Log$
|
||||
Revision 1.6 1998-12-11 00:03:25 peter
|
||||
Revision 1.7 1999-05-04 21:44:52 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.6 1998/12/11 00:03:25 peter
|
||||
+ globtype,tokens,version unit splitted from globals
|
||||
|
||||
Revision 1.5 1998/10/16 14:20:53 daniel
|
||||
|
@ -64,7 +64,10 @@ type
|
||||
implementation
|
||||
|
||||
uses
|
||||
dos;
|
||||
{$ifdef Delphi}
|
||||
dmisc,
|
||||
{$endif Delphi}
|
||||
dos;
|
||||
|
||||
const
|
||||
{$ifdef TP}
|
||||
@ -273,7 +276,10 @@ end;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.1 1999-05-01 13:24:26 peter
|
||||
Revision 1.2 1999-05-04 21:44:53 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.1 1999/05/01 13:24:26 peter
|
||||
* merged nasm compiler
|
||||
* old asm moved to oldasm/
|
||||
|
||||
|
@ -261,7 +261,7 @@ unit pdecl;
|
||||
{ to handle absolute }
|
||||
abssym : pabsolutesym;
|
||||
l : longint;
|
||||
code : word;
|
||||
code : integer;
|
||||
{ c var }
|
||||
newtype : ptypesym;
|
||||
is_dll,
|
||||
@ -792,7 +792,7 @@ unit pdecl;
|
||||
p,p2 : ppropertysym;
|
||||
overriden : psym;
|
||||
hs : string;
|
||||
code : word;
|
||||
code : integer;
|
||||
varspez : tvarspez;
|
||||
sc : pstringcontainer;
|
||||
hp : pdef;
|
||||
@ -2272,7 +2272,10 @@ unit pdecl;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.113 1999-05-01 13:24:30 peter
|
||||
Revision 1.114 1999-05-04 21:44:54 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.113 1999/05/01 13:24:30 peter
|
||||
* merged nasm compiler
|
||||
* old asm moved to oldasm/
|
||||
|
||||
|
@ -39,7 +39,7 @@ unit pexports;
|
||||
|
||||
var
|
||||
hp : pexported_item;
|
||||
code : word;
|
||||
code : integer;
|
||||
DefString:string;
|
||||
ProcName:string;
|
||||
InternalProcName:string;
|
||||
@ -120,7 +120,10 @@ end.
|
||||
|
||||
{
|
||||
$Log$
|
||||
Revision 1.8 1999-03-26 00:05:35 peter
|
||||
Revision 1.9 1999-05-04 21:44:56 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.8 1999/03/26 00:05:35 peter
|
||||
* released valintern
|
||||
+ deffile is now removed when compiling is finished
|
||||
* ^( compiles now correct
|
||||
|
@ -534,6 +534,31 @@ unit pexpr;
|
||||
afterassignment:=prevafterassn;
|
||||
end;
|
||||
|
||||
procedure handle_procvar(procvar : pprocvardef;var t : ptree);
|
||||
|
||||
begin
|
||||
if ((procvar^.options and pomethodpointer)<>0) then
|
||||
begin
|
||||
if (t^.methodpointer^.resulttype^.deftype=objectdef) and
|
||||
(pobjectdef(t^.methodpointer^.resulttype)^.isclass) and
|
||||
(proc_to_procvar_equal(procvar,pprocsym(t^.symtableentry)^.definition)) then
|
||||
begin
|
||||
t^.treetype:=loadn;
|
||||
t^.disposetyp:=dt_left;
|
||||
t^.left:=t^.methodpointer;
|
||||
t^.resulttype:=pprocsym(t^.symtableprocentry)^.definition;
|
||||
t^.symtableentry:=pvarsym(t^.symtableprocentry);
|
||||
end
|
||||
else
|
||||
Message(type_e_mismatch);
|
||||
end
|
||||
else if (proc_to_procvar_equal(getprocvardef,pprocsym(t^.symtableentry)^.definition)) then
|
||||
begin
|
||||
t^.treetype:=loadn;
|
||||
t^.resulttype:=pprocsym(t^.symtableprocentry)^.definition;
|
||||
t^.symtableentry:=t^.symtableprocentry;
|
||||
end;
|
||||
end;
|
||||
|
||||
{ the following procedure handles the access to a property symbol }
|
||||
procedure handle_propertysym(sym : psym;st : psymtable;var p1 : ptree;
|
||||
@ -578,8 +603,12 @@ unit pexpr;
|
||||
p1^.left:=paras;
|
||||
consume(ASSIGNMENT);
|
||||
{ read the expression }
|
||||
getprocvar:=ppropertysym(sym)^.proptype^.deftype=procvardef;
|
||||
p2:=comp_expr(true);
|
||||
if (p2^.treetype<>errorn) and getprocvar then
|
||||
handle_procvar(pprocvardef(ppropertysym(sym)^.proptype),p2);
|
||||
p1^.left:=gencallparanode(p2,p1^.left);
|
||||
getprocvar:=false;
|
||||
end
|
||||
else if ppropertysym(sym)^.writeaccesssym^.typ=varsym then
|
||||
begin
|
||||
@ -928,7 +957,7 @@ unit pexpr;
|
||||
else { not LKLAMMER}
|
||||
if (token=POINT) and
|
||||
(pd^.deftype=objectdef) and
|
||||
((pobjectdef(pd)^.options and oo_is_class)=0) then
|
||||
not(pobjectdef(pd)^.isclass) then
|
||||
begin
|
||||
consume(POINT);
|
||||
if assigned(procinfo._class) then
|
||||
@ -983,7 +1012,7 @@ unit pexpr;
|
||||
begin
|
||||
{ class reference ? }
|
||||
if (pd^.deftype=objectdef)
|
||||
and ((pobjectdef(pd)^.options and oo_is_class)<>0) then
|
||||
and pobjectdef(pd)^.isclass then
|
||||
begin
|
||||
p1:=gentypenode(pd);
|
||||
p1^.resulttype:=pd;
|
||||
@ -1056,7 +1085,7 @@ unit pexpr;
|
||||
again,p1,pd);
|
||||
if possible_error and
|
||||
((p1^.procdefinition^.options and poclassmethod)=0) then
|
||||
Message(parser_e_only_class_methods);
|
||||
Message(parser_e_only_class_methods);
|
||||
end;
|
||||
propertysym : begin
|
||||
{ access to property in a method }
|
||||
@ -1869,29 +1898,7 @@ unit pexpr;
|
||||
end;
|
||||
p2:=sub_expr(opcompare,true);
|
||||
if getprocvar and (p2^.treetype=calln) then
|
||||
begin
|
||||
if ((getprocvardef^.options and pomethodpointer)<>0) then
|
||||
begin
|
||||
if (p2^.methodpointer^.resulttype^.deftype=objectdef) and
|
||||
(pobjectdef(p2^.methodpointer^.resulttype)^.isclass) and
|
||||
(proc_to_procvar_equal(getprocvardef,pprocsym(p2^.symtableentry)^.definition)) then
|
||||
begin
|
||||
p2^.treetype:=loadn;
|
||||
p2^.disposetyp:=dt_left;
|
||||
p2^.left:=p2^.methodpointer;
|
||||
p2^.resulttype:=pprocsym(p2^.symtableprocentry)^.definition;
|
||||
p2^.symtableentry:=pvarsym(p2^.symtableprocentry);
|
||||
end
|
||||
else
|
||||
Message(type_e_mismatch);
|
||||
end
|
||||
else if (proc_to_procvar_equal(getprocvardef,pprocsym(p2^.symtableentry)^.definition)) then
|
||||
begin
|
||||
p2^.treetype:=loadn;
|
||||
p2^.resulttype:=pprocsym(p2^.symtableprocentry)^.definition;
|
||||
p2^.symtableentry:=p2^.symtableprocentry;
|
||||
end;
|
||||
end;
|
||||
handle_procvar(getprocvardef,p2);
|
||||
getprocvar:=false;
|
||||
p1:=gennode(assignn,p1,p2);
|
||||
end;
|
||||
@ -1972,7 +1979,10 @@ unit pexpr;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.99 1999-05-01 13:24:31 peter
|
||||
Revision 1.100 1999-05-04 21:44:57 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.99 1999/05/01 13:24:31 peter
|
||||
* merged nasm compiler
|
||||
* old asm moved to oldasm/
|
||||
|
||||
|
@ -229,7 +229,9 @@ begin
|
||||
exitproc:=@myexit;
|
||||
{$ifndef VER0_99_5}
|
||||
{$ifndef TP}
|
||||
{$ifndef Delphi}
|
||||
heapblocks:=true;
|
||||
{$endif Delphi}
|
||||
{$endif}
|
||||
{$endif}
|
||||
{$ifdef UseOverlay}
|
||||
@ -241,7 +243,10 @@ begin
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.1 1998-09-18 16:03:44 florian
|
||||
Revision 1.2 1999-05-04 21:44:58 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.1 1998/09/18 16:03:44 florian
|
||||
* some changes to compile with Delphi
|
||||
|
||||
Revision 1.28 1998/08/26 15:31:17 peter
|
||||
|
@ -360,7 +360,8 @@ end;
|
||||
function tppufile.GetPPUVersion:longint;
|
||||
var
|
||||
l : longint;
|
||||
code : word;
|
||||
code : integer;
|
||||
|
||||
begin
|
||||
Val(header.ver[1]+header.ver[2]+header.ver[3],l,code);
|
||||
if code=0 then
|
||||
@ -396,7 +397,12 @@ end;
|
||||
function tppufile.open:boolean;
|
||||
var
|
||||
ofmode : byte;
|
||||
{$ifdef delphi}
|
||||
i : integer;
|
||||
{$else delphi}
|
||||
i : word;
|
||||
{$endif delphi}
|
||||
|
||||
begin
|
||||
open:=false;
|
||||
assign(f,fname);
|
||||
@ -868,7 +874,10 @@ end;
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.30 1999-04-26 18:30:00 peter
|
||||
Revision 1.31 1999-05-04 21:44:59 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.30 1999/04/26 18:30:00 peter
|
||||
* farpointerdef moved into pointerdef.is_far
|
||||
|
||||
Revision 1.29 1999/04/26 13:31:41 peter
|
||||
|
@ -990,7 +990,7 @@ end;
|
||||
var expr: string;
|
||||
tempstr: string;
|
||||
r : bestreal;
|
||||
code : word;
|
||||
code : integer;
|
||||
negativ : boolean;
|
||||
errorflag: boolean;
|
||||
Begin
|
||||
@ -2056,7 +2056,10 @@ begin
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.42 1999-05-02 14:25:07 peter
|
||||
Revision 1.43 1999-05-04 21:45:01 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.42 1999/05/02 14:25:07 peter
|
||||
* only allow *<reg/ref> when call/jmp is used
|
||||
|
||||
Revision 1.41 1999/05/01 13:48:39 peter
|
||||
|
@ -894,7 +894,7 @@ Procedure BuildBracketExpression(var Instr: TInstruction);
|
||||
var
|
||||
l : longint;
|
||||
hs : string;
|
||||
code : word;
|
||||
code : integer;
|
||||
hreg,
|
||||
oldbase : tregister;
|
||||
GotPlus,Negative : boolean;
|
||||
@ -1724,7 +1724,10 @@ begin
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.31 1999-05-01 13:48:41 peter
|
||||
Revision 1.32 1999-05-04 21:45:02 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.31 1999/05/01 13:48:41 peter
|
||||
* merged nasm compiler
|
||||
|
||||
Revision 1.6 1999/04/26 23:26:18 peter
|
||||
|
@ -28,6 +28,9 @@ unit scanner;
|
||||
interface
|
||||
|
||||
uses
|
||||
{$ifdef Delphi}
|
||||
dmisc,
|
||||
{$endif Delphi}
|
||||
globtype,version,tokens,
|
||||
cobjects,globals,verbose,comphook,files;
|
||||
|
||||
@ -1651,7 +1654,10 @@ begin
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.81 1999-04-07 14:36:44 pierre
|
||||
Revision 1.82 1999-05-04 21:45:04 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.81 1999/04/07 14:36:44 pierre
|
||||
+ better preproc stack checking and report
|
||||
|
||||
Revision 1.80 1999/04/06 11:20:59 peter
|
||||
|
@ -106,7 +106,7 @@
|
||||
procedure writedefref(p : pdef);
|
||||
begin
|
||||
if p=nil then
|
||||
current_ppu^.putlongint($ffffffff)
|
||||
current_ppu^.putlongint(-1)
|
||||
else
|
||||
begin
|
||||
if p^.owner^.symtabletype=staticsymtable then
|
||||
@ -129,7 +129,7 @@
|
||||
procedure writesymref(p : psym);
|
||||
begin
|
||||
if p=nil then
|
||||
current_ppu^.putlongint($ffffffff)
|
||||
current_ppu^.putlongint(-1)
|
||||
else
|
||||
begin
|
||||
if p^.owner^.symtabletype=staticsymtable then
|
||||
@ -510,7 +510,10 @@
|
||||
|
||||
{
|
||||
$Log$
|
||||
Revision 1.38 1999-04-26 13:31:51 peter
|
||||
Revision 1.39 1999-05-04 21:45:06 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.38 1999/04/26 13:31:51 peter
|
||||
* release storenumber,double_checksum
|
||||
|
||||
Revision 1.37 1999/04/21 09:43:53 peter
|
||||
|
@ -1273,9 +1273,11 @@
|
||||
((properties and sp_static)<>0) then
|
||||
begin
|
||||
if (cs_gdb_gsym in aktglobalswitches) then st := 'G' else st := 'S';
|
||||
{$ifndef Delphi}
|
||||
stabstring := strpnew('"'+owner^.name^+'__'+name+':'+
|
||||
+definition^.numberstring+'",'+
|
||||
tostr(N_LCSYM)+',0,'+tostr(fileinfo.line)+','+mangledname);
|
||||
{$endif}
|
||||
end
|
||||
else if (owner^.symtabletype = globalsymtable) or
|
||||
(owner^.symtabletype = unitsymtable) then
|
||||
@ -1972,7 +1974,10 @@
|
||||
|
||||
{
|
||||
$Log$
|
||||
Revision 1.84 1999-05-04 16:05:13 pierre
|
||||
Revision 1.85 1999-05-04 21:45:07 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.84 1999/05/04 16:05:13 pierre
|
||||
* fix for unitsym problem
|
||||
|
||||
Revision 1.83 1999/04/28 06:02:13 florian
|
||||
|
@ -190,6 +190,20 @@ implementation
|
||||
end;
|
||||
|
||||
{$else}
|
||||
{$ifdef Delphi}
|
||||
|
||||
function setjmp(var rec : jmp_buf) : longint;
|
||||
|
||||
begin
|
||||
result:=0;
|
||||
end;
|
||||
|
||||
procedure longjmp(const rec : jmp_buf;return_value : longint);
|
||||
|
||||
begin
|
||||
end;
|
||||
|
||||
{$else Delphi}
|
||||
|
||||
function setjmp(var rec : jmp_buf) : longint;
|
||||
begin
|
||||
@ -330,13 +344,16 @@ implementation
|
||||
ret
|
||||
end;
|
||||
end;
|
||||
|
||||
{$endif Delphi}
|
||||
{$endif TP}
|
||||
|
||||
end.
|
||||
{
|
||||
$Log$
|
||||
Revision 1.5 1998-10-28 18:26:23 pierre
|
||||
Revision 1.6 1999-05-04 21:45:08 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.5 1998/10/28 18:26:23 pierre
|
||||
* removed some erros after other errors (introduced by useexcept)
|
||||
* stabs works again correctly (for how long !)
|
||||
|
||||
|
@ -123,7 +123,7 @@ end;
|
||||
function SetVerbosity(const s:string):boolean;
|
||||
var
|
||||
m : Longint;
|
||||
i : Word;
|
||||
i : Integer;
|
||||
inverse : boolean;
|
||||
c : char;
|
||||
begin
|
||||
@ -133,11 +133,12 @@ begin
|
||||
status.verbosity:=m
|
||||
else
|
||||
begin
|
||||
for i:=1 to length(s) do
|
||||
i:=1;
|
||||
while i<=length(s) do
|
||||
begin
|
||||
c:=upcase(s[i]);
|
||||
inverse:=false;
|
||||
{ on/off ? }
|
||||
{ on/off ? }
|
||||
if (i<length(s)) then
|
||||
case s[i+1] of
|
||||
'-' : begin
|
||||
@ -146,7 +147,7 @@ begin
|
||||
end;
|
||||
'+' : inc(i);
|
||||
end;
|
||||
{ handle switch }
|
||||
{ handle switch }
|
||||
case c of
|
||||
{ Special cases }
|
||||
'A' : status.verbosity:=V_All;
|
||||
@ -225,6 +226,7 @@ begin
|
||||
else
|
||||
status.verbosity:=status.verbosity or V_Assem;
|
||||
end;
|
||||
inc(i);
|
||||
end;
|
||||
end;
|
||||
if status.verbosity=0 then
|
||||
@ -465,7 +467,10 @@ end.
|
||||
|
||||
{
|
||||
$Log$
|
||||
Revision 1.37 1999-04-21 07:41:06 pierre
|
||||
Revision 1.38 1999-05-04 21:45:09 florian
|
||||
* changes to compile it with Delphi 4.0
|
||||
|
||||
Revision 1.37 1999/04/21 07:41:06 pierre
|
||||
+ added -vz for assembler specifc comments
|
||||
|
||||
Revision 1.36 1999/03/24 23:17:44 peter
|
||||
|
Loading…
Reference in New Issue
Block a user