- remove $IFDEF DELPHI and related code

- remove $IFDEF FPCPROCVAR and related code
This commit is contained in:
mazen 2004-10-15 09:14:16 +00:00
parent 11af056622
commit 581b52422c
61 changed files with 1085 additions and 645 deletions

View File

@ -198,11 +198,7 @@ interface
end; end;
TAsmObjectDataClass = class of TAsmObjectData; TAsmObjectDataClass = class of TAsmObjectData;
{$ifndef delphi}
tasmsymbolidxarr = array[0..($7fffffff div sizeof(pointer))] of tasmsymbol; tasmsymbolidxarr = array[0..($7fffffff div sizeof(pointer))] of tasmsymbol;
{$else}
tasmsymbolidxarr = array[0..high(word)] of tasmsymbol;
{$endif}
pasmsymbolidxarr = ^tasmsymbolidxarr; pasmsymbolidxarr = ^tasmsymbolidxarr;
TAsmLibraryData = class(TLinkedListItem) TAsmLibraryData = class(TLinkedListItem)
@ -253,11 +249,7 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$else}
strings, strings,
{$endif}
verbose; verbose;
const const
@ -949,7 +941,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.21 2004-07-22 10:09:10 jonas Revision 1.22 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.21 2004/07/22 10:09:10 jonas
* fixed relabeling properly now :) * fixed relabeling properly now :)
Revision 1.20 2004/07/22 10:07:09 jonas Revision 1.20 2004/07/22 10:07:09 jonas

View File

@ -615,11 +615,7 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$else}
strings, strings,
{$endif}
verbose; verbose;
const const
@ -2230,7 +2226,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.90 2004-10-05 20:41:01 peter Revision 1.91 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.90 2004/10/05 20:41:01 peter
* more spilling rewrites * more spilling rewrites
Revision 1.89 2004/09/26 17:45:29 peter Revision 1.89 2004/09/26 17:45:29 peter

View File

@ -36,9 +36,6 @@ unit cpubase;
cpuinfo, cpuinfo,
aasmbase, aasmbase,
cgbase cgbase
{$ifdef delphi}
,dmisc
{$endif}
; ;
@ -592,7 +589,11 @@ unit cpubase;
end. end.
{ {
$Log$ $Log$
Revision 1.31 2004-06-20 08:55:31 florian Revision 1.32 2004-10-15 09:15:34 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.31 2004/06/20 08:55:31 florian
* logs truncated * logs truncated
Revision 1.30 2004/06/16 20:07:10 florian Revision 1.30 2004/06/16 20:07:10 florian

View File

@ -465,7 +465,7 @@ implementation
writesymtable(tobjectdef(ttypesym(hp).restype.def).symtable); writesymtable(tobjectdef(ttypesym(hp).restype.def).symtable);
end; end;
procsym : procsym :
Tprocsym(hp).foreach_procdef_static({$IFDEF FPCPROCVAR}@{$ENDIF}writelocalsymtables,nil); Tprocsym(hp).foreach_procdef_static(@writelocalsymtables,nil);
end; end;
hp:=tstoredsym(hp.indexnext); hp:=tstoredsym(hp.indexnext);
end; end;
@ -516,7 +516,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.18 2004-06-20 08:55:28 florian Revision 1.19 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.18 2004/06/20 08:55:28 florian
* logs truncated * logs truncated
Revision 1.17 2004/02/11 22:00:10 peter Revision 1.17 2004/02/11 22:00:10 peter

View File

@ -103,7 +103,7 @@ end;
begin begin
{$ifndef nocatch} {$ifndef nocatch}
{$ifdef has_signal} {$ifdef has_signal}
NewSignal:=SignalHandler({$ifdef fpcprocvar}@{$endif}CatchSignal); NewSignal:=SignalHandler(@CatchSignal);
{$ifndef sunos} {$ifndef sunos}
OldSigSegm:={$ifdef havelinuxrtl10}Signal{$else}{$ifdef Unix}fpSignal{$else}Signal{$endif}{$endif} (SIGSEGV,NewSignal); OldSigSegm:={$ifdef havelinuxrtl10}Signal{$else}{$ifdef Unix}fpSignal{$else}Signal{$endif}{$endif} (SIGSEGV,NewSignal);
{$endif} // lxrun on solaris hooks this for handling linux-calls! {$endif} // lxrun on solaris hooks this for handling linux-calls!
@ -115,7 +115,11 @@ end.
{ {
$Log$ $Log$
Revision 1.19 2004-09-09 08:19:47 olle Revision 1.20 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.19 2004/09/09 08:19:47 olle
+ Added argument to Stop + Added argument to Stop
Revision 1.18 2004/06/20 08:55:28 florian Revision 1.18 2004/06/20 08:55:28 florian

View File

@ -370,11 +370,7 @@ implementation
procedure tmemdebug.start; procedure tmemdebug.start;
begin begin
{$ifdef Delphi}
startmem:=0;
{$else}
startmem:=memavail; startmem:=memavail;
{$endif Delphi}
end; end;
@ -382,9 +378,7 @@ implementation
begin begin
if startmem<>0 then if startmem<>0 then
begin begin
{$ifndef Delphi}
inc(TotalMem,memavail-startmem); inc(TotalMem,memavail-startmem);
{$endif}
startmem:=0; startmem:=0;
end; end;
end; end;
@ -399,13 +393,11 @@ implementation
procedure tmemdebug.show; procedure tmemdebug.show;
begin begin
{$ifndef Delphi}
write('memory [',infostr,'] '); write('memory [',infostr,'] ');
if TotalMem>0 then if TotalMem>0 then
writeln(DStr(TotalMem shr 10),' Kb released') writeln(DStr(TotalMem shr 10),' Kb released')
else else
writeln(DStr((-TotalMem) shr 10),' Kb allocated'); writeln(DStr((-TotalMem) shr 10),' Kb allocated');
{$endif Delphi}
end; end;
@ -2356,7 +2348,11 @@ end;
end. end.
{ {
$Log$ $Log$
Revision 1.37 2004-10-04 20:43:28 peter Revision 1.38 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.37 2004/10/04 20:43:28 peter
* insertlistbefore added * insertlistbefore added
Revision 1.36 2004/09/13 20:26:26 peter Revision 1.36 2004/09/13 20:26:26 peter

View File

@ -36,9 +36,6 @@ unit cg64f32;
cpuinfo,cpubase,cpupara, cpuinfo,cpubase,cpupara,
cgbase,cgobj,parabase, cgbase,cgobj,parabase,
node,symtype node,symtype
{$ifdef delphi}
,dmisc
{$endif}
; ;
type type
@ -780,7 +777,11 @@ unit cg64f32;
end. end.
{ {
$Log$ $Log$
Revision 1.63 2004-09-25 14:23:54 peter Revision 1.64 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.63 2004/09/25 14:23:54 peter
* ungetregister is now only used for cpuregisters, renamed to * ungetregister is now only used for cpuregisters, renamed to
ungetcpuregister ungetcpuregister
* renamed (get|unget)explicitregister(s) to ..cpuregister * renamed (get|unget)explicitregister(s) to ..cpuregister

View File

@ -37,9 +37,6 @@ unit cgobj;
interface interface
uses uses
{$ifdef delphi}
dmisc,
{$endif}
cclasses,globtype, cclasses,globtype,
cpubase,cpuinfo,cgbase,parabase, cpubase,cpuinfo,cgbase,parabase,
aasmbase,aasmtai,aasmcpu, aasmbase,aasmtai,aasmcpu,
@ -541,7 +538,7 @@ implementation
procedure tcg.init_register_allocators; procedure tcg.init_register_allocators;
begin begin
fillchar(rg,sizeof(rg),0); fillchar(rg,sizeof(rg),0);
add_reg_instruction_hook:={$ifdef FPCPROCVAR}@{$endif}add_reg_instruction; add_reg_instruction_hook:=@add_reg_instruction;
end; end;
@ -2095,7 +2092,11 @@ finalization
end. end.
{ {
$Log$ $Log$
Revision 1.178 2004-10-13 21:12:51 peter Revision 1.179 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.178 2004/10/13 21:12:51 peter
* -Or fixes for open array * -Or fixes for open array
Revision 1.177 2004/10/11 15:46:45 peter Revision 1.177 2004/10/11 15:46:45 peter

View File

@ -148,13 +148,8 @@ unit charset;
end; end;
flag:=umf_noinfo; flag:=umf_noinfo;
end; end;
{$ifdef delphi}
data^.flag:=flag;
data^.unicode:=unicodevalue;
{$else}
data[charpos].flag:=flag; data[charpos].flag:=flag;
data[charpos].unicode:=unicodevalue; data[charpos].unicode:=unicodevalue;
{$endif delphi}
if charpos>lastchar then if charpos>lastchar then
lastchar:=charpos; lastchar:=charpos;
end; end;
@ -216,11 +211,7 @@ unit charset;
begin begin
if ord(c)<=p^.lastchar then if ord(c)<=p^.lastchar then
{$ifdef Delphi}
getunicode:=p^.map.unicode
{$else}
getunicode:=p^.map[ord(c)].unicode getunicode:=p^.map[ord(c)].unicode
{$endif}
else else
getunicode:=0; getunicode:=0;
end; end;
@ -234,11 +225,7 @@ unit charset;
{ at least map to space } { at least map to space }
getascii:=#32; getascii:=#32;
for i:=0 to p^.lastchar do for i:=0 to p^.lastchar do
{$ifdef Delphi}
if p^.map.unicode=c then
{$else}
if p^.map[i].unicode=c then if p^.map[i].unicode=c then
{$endif}
begin begin
if i<256 then if i<256 then
getascii:=chr(i) getascii:=chr(i)
@ -267,7 +254,11 @@ finalization
end. end.
{ {
$Log$ $Log$
Revision 1.5 2004-06-20 08:55:29 florian Revision 1.6 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.5 2004/06/20 08:55:29 florian
* logs truncated * logs truncated
} }

View File

@ -64,11 +64,7 @@ implementation
uses uses
cutils, cutils,
{$ifdef DELPHI}
sysutils;
{$else DELPHI}
strings; strings;
{$endif DELPHI}
function MsgReplace(const s:string;const args:array of string):string; function MsgReplace(const s:string;const args:array of string):string;
@ -418,7 +414,11 @@ end;
end. end.
{ {
$Log$ $Log$
Revision 1.12 2004-06-20 08:55:29 florian Revision 1.13 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.12 2004/06/20 08:55:29 florian
* logs truncated * logs truncated
Revision 1.11 2004/06/16 20:07:07 florian Revision 1.11 2004/06/16 20:07:07 florian

View File

@ -127,17 +127,17 @@ type
tgetnamedfiletimefunc = function(const filename: string): longint; tgetnamedfiletimefunc = function(const filename: string): longint;
const const
do_stop : tstopprocedure = {$ifdef FPCPROCVAR}@{$endif}def_stop; do_stop : tstopprocedure = @def_stop;
do_status : tstatusfunction = {$ifdef FPCPROCVAR}@{$endif}def_status; do_status : tstatusfunction = @def_status;
do_comment : tcommentfunction = {$ifdef FPCPROCVAR}@{$endif}def_comment; do_comment : tcommentfunction = @def_comment;
do_internalerror : tinternalerrorfunction = {$ifdef FPCPROCVAR}@{$endif}def_internalerror; do_internalerror : tinternalerrorfunction = @def_internalerror;
do_initsymbolinfo : tinitsymbolinfoproc = {$ifdef FPCPROCVAR}@{$endif}def_initsymbolinfo; do_initsymbolinfo : tinitsymbolinfoproc = @def_initsymbolinfo;
do_donesymbolinfo : tdonesymbolinfoproc = {$ifdef FPCPROCVAR}@{$endif}def_donesymbolinfo; do_donesymbolinfo : tdonesymbolinfoproc = @def_donesymbolinfo;
do_extractsymbolinfo : textractsymbolinfoproc = {$ifdef FPCPROCVAR}@{$endif}def_extractsymbolinfo; do_extractsymbolinfo : textractsymbolinfoproc = @def_extractsymbolinfo;
do_openinputfile : topeninputfilefunc = {$ifdef FPCPROCVAR}@{$endif}def_openinputfile; do_openinputfile : topeninputfilefunc = @def_openinputfile;
do_getnamedfiletime : tgetnamedfiletimefunc = {$ifdef FPCPROCVAR}@{$endif}def_getnamedfiletime; do_getnamedfiletime : tgetnamedfiletimefunc = @def_getnamedfiletime;
implementation implementation
@ -208,17 +208,13 @@ begin
{ Status info?, Called every line } { Status info?, Called every line }
if ((status.verbosity and V_Status)<>0) then if ((status.verbosity and V_Status)<>0) then
begin begin
{$ifndef Delphi}
if (status.compiledlines=1) then if (status.compiledlines=1) then
WriteLn(memavail shr 10,' Kb Free'); WriteLn(memavail shr 10,' Kb Free');
{$endif Delphi}
if (status.currentline>0) and (status.currentline mod 100=0) then if (status.currentline>0) and (status.currentline mod 100=0) then
{$ifdef FPC} {$ifdef FPC}
WriteLn(status.currentline,' ',DStr(memavail shr 10),'/',DStr(system.heapsize shr 10),' Kb Free'); WriteLn(status.currentline,' ',DStr(memavail shr 10),'/',DStr(system.heapsize shr 10),' Kb Free');
{$else} {$else}
{$ifndef Delphi}
WriteLn(status.currentline,' ',DStr(memavail shr 10),' Kb Free'); WriteLn(status.currentline,' ',DStr(memavail shr 10),' Kb Free');
{$endif Delphi}
{$endif} {$endif}
end end
end; end;
@ -360,30 +356,33 @@ end;
Function def_GetNamedFileTime (Const F : String) : Longint; Function def_GetNamedFileTime (Const F : String) : Longint;
var var
L : Longint;
{$IFDEF USE_SYSUTILS} {$IFDEF USE_SYSUTILS}
info : TSearchRec; fh : THandle;
{$ELSE USE_SYSUTILS} {$ELSE USE_SYSUTILS}
info : SearchRec; info : SearchRec;
{$ENDIF USE_SYSUTILS} {$ENDIF USE_SYSUTILS}
begin begin
l:=-1; Result := -1;
{$IFDEF USE_SYSUTILS} {$IFDEF USE_SYSUTILS}
if FindFirst (F,faArchive+faReadOnly+faHidden,info) = 0 fh := FileOpen(f, faArchive+faReadOnly+faHidden);
then Result := FileGetDate(fh);
FileClose(fh);
{$ELSE USE_SYSUTILS} {$ELSE USE_SYSUTILS}
FindFirst (F,archive+readonly+hidden,info); FindFirst (F,archive+readonly+hidden,info);
if DosError=0 then if DosError=0 then
{$ENDIF USE_SYSUTILS} Result := info.time;
l:=info.time;
FindClose(info); FindClose(info);
def_GetNamedFileTime:=l; {$ENDIF USE_SYSUTILS}
end; end;
end. end.
{ {
$Log$ $Log$
Revision 1.30 2004-10-14 18:16:17 mazen Revision 1.31 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.30 2004/10/14 18:16:17 mazen
* USE_SYSUTILS merged successfully : cycles with and without defines * USE_SYSUTILS merged successfully : cycles with and without defines
* Need to be optimized in performance * Need to be optimized in performance

View File

@ -331,7 +331,7 @@ end;
procedure minimal_stop(err:longint); procedure minimal_stop(err:longint);
begin begin
DoneCompiler; DoneCompiler;
olddo_stop{$ifdef FPCPROCVAR}(err){$endif}; olddo_stop(err);
end; end;
@ -377,7 +377,7 @@ var
{$endif} {$endif}
begin begin
olddo_stop:=do_stop; olddo_stop:=do_stop;
do_stop:={$ifdef FPCPROCVAR}@{$endif}minimal_stop; do_stop:=@minimal_stop;
{ Initialize the compiler } { Initialize the compiler }
InitCompiler(cmd); InitCompiler(cmd);
@ -395,7 +395,7 @@ begin
if setjmp(recoverpos)=0 then if setjmp(recoverpos)=0 then
begin begin
recoverpospointer:=@recoverpos; recoverpospointer:=@recoverpos;
do_stop:={$ifdef FPCPROCVAR}@{$endif}recoverstop; do_stop:=@recoverstop;
{$endif USEEXCEPT} {$endif USEEXCEPT}
starttime:=getrealtime; starttime:=getrealtime;
{$ifdef PREPROCWRITE} {$ifdef PREPROCWRITE}
@ -433,14 +433,18 @@ begin
Writeln('Memory used (heapsize): ',DStr(system.Heapsize shr 10),' Kb'); Writeln('Memory used (heapsize): ',DStr(system.Heapsize shr 10),' Kb');
{$endif SHOWUSEDMEM} {$endif SHOWUSEDMEM}
{$ifdef fixLeaksOnError} {$ifdef fixLeaksOnError}
do_stop{$ifdef FPCPROCVAR}(){$endif}; do_stop;
{$endif fixLeaksOnError} {$endif fixLeaksOnError}
end; end;
end. end.
{ {
$Log$ $Log$
Revision 1.48 2004-10-14 17:17:25 mazen Revision 1.49 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.48 2004/10/14 17:17:25 mazen
* use SysUtils unit instead of Dos Unit * use SysUtils unit instead of Dos Unit
Revision 1.47 2004/09/08 11:23:31 michael Revision 1.47 2004/09/08 11:23:31 michael

View File

@ -141,11 +141,7 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils
{$else}
strings strings
{$endif}
; ;
var var
@ -1256,7 +1252,11 @@ initialization
end. end.
{ {
$Log$ $Log$
Revision 1.45 2004-10-14 14:55:12 mazen Revision 1.46 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.45 2004/10/14 14:55:12 mazen
* use SysUtils unit instead of Dos Unit * use SysUtils unit instead of Dos Unit
+ overload Replace to use AnsiString + overload Replace to use AnsiString

View File

@ -412,7 +412,7 @@ uses
procedure tppumodule.writeusedmacros; procedure tppumodule.writeusedmacros;
begin begin
ppufile.do_crc:=false; ppufile.do_crc:=false;
tscannerfile(scanner).macros.foreach({$ifdef FPCPROCVAR}@{$endif}writeusedmacro,nil); tscannerfile(scanner).macros.foreach(@writeusedmacro,nil);
ppufile.writeentry(ibusedmacros); ppufile.writeentry(ibusedmacros);
ppufile.do_crc:=true; ppufile.do_crc:=true;
end; end;
@ -556,7 +556,7 @@ uses
{ get an ordered list of all symbols to put in the ppu } { get an ordered list of all symbols to put in the ppu }
getmem(librarydata.asmsymbolidx,librarydata.asmsymbolppuidx*sizeof(pointer)); getmem(librarydata.asmsymbolidx,librarydata.asmsymbolppuidx*sizeof(pointer));
fillchar(librarydata.asmsymbolidx^,librarydata.asmsymbolppuidx*sizeof(pointer),0); fillchar(librarydata.asmsymbolidx^,librarydata.asmsymbolppuidx*sizeof(pointer),0);
librarydata.symbolsearch.foreach({$ifdef FPCPROCVAR}@{$endif}putasmsymbol_in_idx,nil); librarydata.symbolsearch.foreach(@putasmsymbol_in_idx,nil);
{ write the number of symbols } { write the number of symbols }
ppufile.putlongint(librarydata.asmsymbolppuidx); ppufile.putlongint(librarydata.asmsymbolppuidx);
{ write the symbols from the indexed list to the ppu } { write the symbols from the indexed list to the ppu }
@ -1512,7 +1512,11 @@ uses
end. end.
{ {
$Log$ $Log$
Revision 1.62 2004-09-13 20:27:27 peter Revision 1.63 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.62 2004/09/13 20:27:27 peter
* remove check for shortunitname, it broke units with 8 and 9 chars * remove check for shortunitname, it broke units with 8 and 9 chars
with the first 8 chars being equal with the first 8 chars being equal

View File

@ -27,11 +27,7 @@ unit gdb;
interface interface
uses uses
{$ifdef delphi}
sysutils,
{$else}
strings, strings,
{$endif}
globtype, globtype,
aasmtai; aasmtai;
@ -239,7 +235,11 @@ end.
{ {
$Log$ $Log$
Revision 1.19 2004-06-20 08:55:29 florian Revision 1.20 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.19 2004/06/20 08:55:29 florian
* logs truncated * logs truncated
Revision 1.18 2004/03/08 22:07:46 peter Revision 1.18 2004/03/08 22:07:46 peter

View File

@ -1112,10 +1112,6 @@ implementation
else else
hs:=currpath; hs:=currpath;
hsd:=SplitPath(hs); hsd:=SplitPath(hs);
{$IFDEF USE_SYSUTILS}
{$ELSE USE_SYSUTILS}
findfirst(hs,directory,dir);
{$ENDIF USE_SYSUTILS}
subdirfound:=false; subdirfound:=false;
{$IFDEF USE_SYSUTILS} {$IFDEF USE_SYSUTILS}
if findfirst(hs,faDirectory,dir) = 0 if findfirst(hs,faDirectory,dir) = 0
@ -1134,6 +1130,7 @@ implementation
WarnNonExistingPath(currpath); WarnNonExistingPath(currpath);
until findnext(dir) <> 0; until findnext(dir) <> 0;
{$ELSE USE_SYSUTILS} {$ELSE USE_SYSUTILS}
findfirst(hs,directory,dir);
while doserror=0 do while doserror=0 do
begin begin
if (dir.name<>'.') and if (dir.name<>'.') and
@ -1414,7 +1411,7 @@ implementation
{$ifdef GETENVOK} {$ifdef GETENVOK}
{$undef GETENVOK} {$undef GETENVOK}
{$else} {$else}
GetEnvPchar:=StrPNew({$ifdef delphi}DMisc{$else}Dos{$endif}.Getenv(envname)); GetEnvPchar:=StrPNew(Dos.Getenv(envname));
{$endif} {$endif}
end; end;
@ -2121,7 +2118,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.144 2004-10-14 18:16:17 mazen Revision 1.145 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.144 2004/10/14 18:16:17 mazen
* USE_SYSUTILS merged successfully : cycles with and without defines * USE_SYSUTILS merged successfully : cycles with and without defines
* Need to be optimized in performance * Need to be optimized in performance

View File

@ -282,7 +282,6 @@ than 255 characters. That's why using Ansi Strings}
(values:longint); (values:longint);
end; end;
{$ifndef Delphi}
{$ifndef xFPC} {$ifndef xFPC}
type type
pguid = ^tguid; pguid = ^tguid;
@ -293,7 +292,6 @@ than 255 characters. That's why using Ansi Strings}
D4: array[0..7] of Byte; D4: array[0..7] of Byte;
end; end;
{$endif} {$endif}
{$endif}
const const
{ link options } { link options }
@ -308,7 +306,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.61 2004-10-14 14:42:57 mazen Revision 1.62 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.61 2004/10/14 14:42:57 mazen
+ Needed types aliases to merge USE_SYSUTILS branch + Needed types aliases to merge USE_SYSUTILS branch
Revision 1.60 2004/09/26 17:45:30 peter Revision 1.60 2004/09/26 17:45:30 peter

View File

@ -50,9 +50,6 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$endif}
cutils,globtype,globals,systems,cclasses, cutils,globtype,globals,systems,cclasses,
verbose,finput,fmodule,script,cpuinfo, verbose,finput,fmodule,script,cpuinfo,
itx86int, itx86int,
@ -765,7 +762,7 @@ ait_stab_function_name : ;
procedure T386IntelAssembler.WriteExternals; procedure T386IntelAssembler.WriteExternals;
begin begin
currentasmlist:=self; currentasmlist:=self;
objectlibrary.symbolsearch.foreach_static({$ifdef fpcprocvar}@{$endif}writeexternal,nil); objectlibrary.symbolsearch.foreach_static(@writeexternal,nil);
end; end;
@ -878,7 +875,11 @@ initialization
end. end.
{ {
$Log$ $Log$
Revision 1.51 2004-09-26 17:45:30 peter Revision 1.52 2004-10-15 09:16:21 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.51 2004/09/26 17:45:30 peter
* simple regvar support, not yet finished * simple regvar support, not yet finished
Revision 1.50 2004/06/20 08:55:31 florian Revision 1.50 2004/06/20 08:55:31 florian

View File

@ -49,9 +49,6 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$endif}
cutils,globtype,globals,systems,cclasses, cutils,globtype,globals,systems,cclasses,
fmodule,finput,verbose,cpuinfo,cgbase fmodule,finput,verbose,cpuinfo,cgbase
; ;
@ -776,7 +773,7 @@ interface
procedure T386NasmAssembler.WriteExternals; procedure T386NasmAssembler.WriteExternals;
begin begin
currentasmlist:=self; currentasmlist:=self;
objectlibrary.symbolsearch.foreach_static({$ifdef fpcprocvar}@{$endif}writeexternal,nil); objectlibrary.symbolsearch.foreach_static(@writeexternal,nil);
end; end;
@ -909,7 +906,11 @@ initialization
end. end.
{ {
$Log$ $Log$
Revision 1.48 2004-09-26 17:45:30 peter Revision 1.49 2004-10-15 09:16:21 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.48 2004/09/26 17:45:30 peter
* simple regvar support, not yet finished * simple regvar support, not yet finished
Revision 1.47 2004/06/20 08:55:31 florian Revision 1.47 2004/06/20 08:55:31 florian

View File

@ -32,9 +32,6 @@ unit cgcpu;
aasmbase,aasmtai,aasmcpu, aasmbase,aasmtai,aasmcpu,
cpubase,cpuinfo,parabase, cpubase,cpuinfo,parabase,
node,symconst node,symconst
{$ifdef delphi}
,dmisc
{$endif}
; ;
type type
@ -574,7 +571,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.56 2004-10-13 21:12:51 peter Revision 1.57 2004-10-15 09:16:21 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.56 2004/10/13 21:12:51 peter
* -Or fixes for open array * -Or fixes for open array
Revision 1.55 2004/10/11 15:46:45 peter Revision 1.55 2004/10/11 15:46:45 peter

View File

@ -48,9 +48,6 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$endif}
systems, systems,
cutils,verbose, cutils,verbose,
symdef,paramgr, symdef,paramgr,
@ -144,7 +141,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.63 2004-09-25 14:23:54 peter Revision 1.64 2004-10-15 09:16:22 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.63 2004/09/25 14:23:54 peter
* ungetregister is now only used for cpuregisters, renamed to * ungetregister is now only used for cpuregisters, renamed to
ungetcpuregister ungetcpuregister
* renamed (get|unget)explicitregister(s) to ..cpuregister * renamed (get|unget)explicitregister(s) to ..cpuregister

View File

@ -1,8 +1,4 @@
{$ifdef Delphi}
const msgtxt : array[0..000154] of string[240]=(
{$else Delphi}
const msgtxt : array[0..000154,1..240] of char=( const msgtxt : array[0..000154,1..240] of char=(
{$endif Delphi}
'01000_T_Compiler: $1'#000+ '01000_T_Compiler: $1'#000+
'01001_D_Compiler OS: $1'#000+ '01001_D_Compiler OS: $1'#000+
'01002_I_Target OS: $1'#000+ '01002_I_Target OS: $1'#000+

View File

@ -1096,7 +1096,7 @@ type
begin begin
objectdf := objectinfo.objinfo; objectdf := objectinfo.objinfo;
if assigned(objectdf.symtable) then if assigned(objectdf.symtable) then
objectdf.symtable.foreach({$ifdef FPCPROCVAR}@{$endif}verifyabstract,nil); objectdf.symtable.foreach(@verifyabstract,nil);
objectinfo:=tobjectinfoitem(objectinfo.next); objectinfo:=tobjectinfoitem(objectinfo.next);
end; end;
if assigned(parents) then if assigned(parents) then
@ -2054,7 +2054,7 @@ type
tempnodes.createstatement := createstatement; tempnodes.createstatement := createstatement;
tempnodes.deletestatement := deletestatement; tempnodes.deletestatement := deletestatement;
setlength(inlinelocals,tprocdef(procdefinition).localst.symindex.count); setlength(inlinelocals,tprocdef(procdefinition).localst.symindex.count);
tprocdef(procdefinition).localst.foreach({$ifdef FPCPROCVAR}@{$endif}createlocaltemps,@tempnodes); tprocdef(procdefinition).localst.foreach(@createlocaltemps,@tempnodes);
createstatement := tempnodes.createstatement; createstatement := tempnodes.createstatement;
deletestatement := tempnodes.deletestatement; deletestatement := tempnodes.deletestatement;
{$endif ndef VER1_0} {$endif ndef VER1_0}
@ -2096,7 +2096,7 @@ type
{ replace complex parameters with temps } { replace complex parameters with temps }
createinlineparas(createstatement,deletestatement); createinlineparas(createstatement,deletestatement);
{ replace the parameter loads with the parameter values } { replace the parameter loads with the parameter values }
foreachnode(result,{$ifdef FPCPROCVAR}@{$endif}replaceparaload,@fileinfo); foreachnode(result,replaceparaload,@fileinfo);
{ free the temps for the locals } { free the temps for the locals }
for i := 0 to high(inlinelocals) do for i := 0 to high(inlinelocals) do
if assigned(inlinelocals[i]) then if assigned(inlinelocals[i]) then
@ -2415,7 +2415,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.251 2004-10-12 14:36:38 peter Revision 1.252 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.251 2004/10/12 14:36:38 peter
* gen high tree makes copy in temp when there is a calln * gen high tree makes copy in temp when there is a calln
Revision 1.250 2004/10/10 20:22:53 peter Revision 1.250 2004/10/10 20:22:53 peter

View File

@ -80,11 +80,7 @@ implementation
cutils,verbose,globals, cutils,verbose,globals,
symconst,symsym,symtable,defutil,paramgr, symconst,symsym,symtable,defutil,paramgr,
{$ifdef GDB} {$ifdef GDB}
{$ifdef delphi}
sysutils,
{$else}
strings, strings,
{$endif}
gdb, gdb,
{$endif GDB} {$endif GDB}
cgbase,pass_2, cgbase,pass_2,
@ -1243,7 +1239,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.177 2004-10-10 20:21:18 peter Revision 1.178 2004-10-15 09:14:16 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.177 2004/10/10 20:21:18 peter
* passing a var parameter to var parameter is now also allowed * passing a var parameter to var parameter is now also allowed
for register locations (=regvars) for register locations (=regvars)

View File

@ -68,9 +68,6 @@ implementation
symconst,symdef,aasmbase,aasmtai,aasmcpu,defutil, symconst,symdef,aasmbase,aasmtai,aasmcpu,defutil,
cpuinfo,cpubase, cpuinfo,cpubase,
cgbase,cgobj, cgbase,cgobj,
{$ifdef delphi}
,dmisc
{$endif}
ncgutil ncgutil
; ;
@ -754,7 +751,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.45 2004-08-08 16:00:56 florian Revision 1.46 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.45 2004/08/08 16:00:56 florian
* constant floating point assignments etc. are now overflow checked * constant floating point assignments etc. are now overflow checked
if Q+ or R+ is turned on if Q+ or R+ is turned on

View File

@ -111,11 +111,7 @@ interface
implementation implementation
uses uses
{$ifdef Delphi}
Sysutils,
{$else}
strings, strings,
{$endif}
cutils,cclasses, cutils,cclasses,
globals,systems,verbose, globals,systems,verbose,
ppu,defutil, ppu,defutil,
@ -2222,7 +2218,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.228 2004-10-14 17:54:06 peter Revision 1.229 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.228 2004/10/14 17:54:06 peter
* add reg_sync when regvars are allocated to fix first use in * add reg_sync when regvars are allocated to fix first use in
loop loop

View File

@ -31,9 +31,6 @@ interface
symtype, symtype,
defutil,defcmp, defutil,defcmp,
nld nld
{$ifdef Delphi}
,dmisc
{$endif}
; ;
type type
@ -2465,7 +2462,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.155 2004-10-12 14:33:41 peter Revision 1.156 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.155 2004/10/12 14:33:41 peter
* give error when converting class to interface are not related * give error when converting class to interface are not related
Revision 1.154 2004/10/11 15:48:15 peter Revision 1.154 2004/10/11 15:48:15 peter

View File

@ -385,13 +385,8 @@ implementation
left:=Tunarynode(left).left; left:=Tunarynode(left).left;
t.left:=nil; t.left:=nil;
t.destroy; t.destroy;
{$ifdef Delphi}
{ How can this be handled in Delphi ? }
RunError(255);
{$else}
{Symdif operator, in case you are wondering:} {Symdif operator, in case you are wondering:}
loopflags:=loopflags >< [lnf_checknegate]; loopflags:=loopflags >< [lnf_checknegate];
{$endif}
end; end;
{ loop instruction } { loop instruction }
if assigned(right) then if assigned(right) then
@ -1429,7 +1424,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.100 2004-09-13 20:28:26 peter Revision 1.101 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.100 2004/09/13 20:28:26 peter
* for loop variable assignment is not allowed anymore * for loop variable assignment is not allowed anymore
Revision 1.99 2004/08/30 12:09:45 michael Revision 1.99 2004/08/30 12:09:45 michael

View File

@ -28,9 +28,6 @@ unit nobj;
interface interface
uses uses
{$ifdef Delphi}
dmisc,
{$endif}
cutils,cclasses, cutils,cclasses,
globtype, globtype,
symdef,symsym, symdef,symsym,
@ -145,11 +142,7 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$else}
strings, strings,
{$endif}
globals,verbose,systems, globals,verbose,systems,
symtable,symconst,symtype,defcmp,paramgr, symtable,symconst,symtype,defcmp,paramgr,
{$ifdef GDB} {$ifdef GDB}
@ -321,7 +314,7 @@ implementation
root:=nil; root:=nil;
count:=0; count:=0;
{ insert all message handlers into a tree, sorted by name } { insert all message handlers into a tree, sorted by name }
_class.symtable.foreach({$ifdef FPCPROCVAR}@{$endif}insertmsgstr,nil); _class.symtable.foreach(@insertmsgstr,nil);
{ write all names } { write all names }
if assigned(root) then if assigned(root) then
@ -362,7 +355,7 @@ implementation
root:=nil; root:=nil;
count:=0; count:=0;
{ insert all message handlers into a tree, sorted by name } { insert all message handlers into a tree, sorted by name }
_class.symtable.foreach({$ifdef FPCPROCVAR}@{$endif}insertmsgint,nil); _class.symtable.foreach(@insertmsgint,nil);
{ now start writing of the message string table } { now start writing of the message string table }
objectlibrary.getdatalabel(r); objectlibrary.getdatalabel(r);
@ -438,7 +431,7 @@ implementation
count:=0; count:=0;
gendmt:=nil; gendmt:=nil;
{ insert all message handlers into a tree, sorted by number } { insert all message handlers into a tree, sorted by number }
_class.symtable.foreach({$ifdef FPCPROCVAR}@{$endif}insertdmtentry); _class.symtable.foreach(insertdmtentry);
if count>0 then if count>0 then
begin begin
@ -504,14 +497,14 @@ implementation
begin begin
count:=0; count:=0;
_class.symtable.foreach({$ifdef FPCPROCVAR}@{$endif}do_count,nil); _class.symtable.foreach(@do_count,nil);
if count>0 then if count>0 then
begin begin
objectlibrary.getdatalabel(l); objectlibrary.getdatalabel(l);
datasegment.concat(tai_align.create(const_align(sizeof(aint)))); datasegment.concat(tai_align.create(const_align(sizeof(aint))));
dataSegment.concat(Tai_label.Create(l)); dataSegment.concat(Tai_label.Create(l));
dataSegment.concat(Tai_const.Create_32bit(count)); dataSegment.concat(Tai_const.Create_32bit(count));
_class.symtable.foreach({$ifdef FPCPROCVAR}@{$endif}genpubmethodtableentry,nil); _class.symtable.foreach(@genpubmethodtableentry,nil);
genpublishedmethodstable:=l; genpublishedmethodstable:=l;
end end
else else
@ -825,7 +818,7 @@ implementation
do_genvmt(p.childof); do_genvmt(p.childof);
{ walk through all public syms } { walk through all public syms }
p.symtable.foreach({$ifdef FPCPROCVAR}@{$endif}eachsym,nil); p.symtable.foreach(@eachsym,nil);
end; end;
begin begin
@ -1389,7 +1382,11 @@ initialization
end. end.
{ {
$Log$ $Log$
Revision 1.77 2004-10-12 14:34:49 peter Revision 1.78 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.77 2004/10/12 14:34:49 peter
* fixed visibility for procsyms * fixed visibility for procsyms
* fixed override check when there was no entry yet * fixed override check when there was no entry yet

View File

@ -167,11 +167,7 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$else}
strings, strings,
{$endif}
cutils,verbose, cutils,verbose,
globals,fmodule; globals,fmodule;
@ -1793,7 +1789,11 @@ initialization
end. end.
{ {
$Log$ $Log$
Revision 1.32 2004-08-27 20:55:08 peter Revision 1.33 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.32 2004/08/27 20:55:08 peter
don't use .rodata, it doesn't work yet don't use .rodata, it doesn't work yet
Revision 1.31 2004/08/25 15:55:32 peter Revision 1.31 2004/08/25 15:55:32 peter

View File

@ -112,11 +112,7 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$else}
strings, strings,
{$endif}
verbose, verbose,
cutils,globals,fmodule; cutils,globals,fmodule;
@ -922,7 +918,11 @@ initialization
end. end.
{ {
$Log$ $Log$
Revision 1.22 2004-08-25 15:55:10 peter Revision 1.23 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.22 2004/08/25 15:55:10 peter
* .rodata section support, disabled by default since it doesn't work * .rodata section support, disabled by default since it doesn't work
yet yet

View File

@ -157,11 +157,7 @@ type Tlxheader = packed record
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$else}
strings, strings,
{$endif}
cutils,verbose, cutils,verbose,
globtype,globals,fmodule; globtype,globals,fmodule;
@ -399,7 +395,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.6 2004-06-20 08:55:30 florian Revision 1.7 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.6 2004/06/20 08:55:30 florian
* logs truncated * logs truncated
} }

View File

@ -1544,13 +1544,8 @@ begin
case quickinfo[i] of case quickinfo[i] of
'O' : 'O' :
addinfo(lower(source_info.shortname)); addinfo(lower(source_info.shortname));
{$ifdef Delphi}
'P' :
addinfo('i386');
{$else Delphi}
'P' : 'P' :
addinfo(source_cpu_string); addinfo(source_cpu_string);
{$endif Delphi}
else else
IllegalPara('-i'+QuickInfo); IllegalPara('-i'+QuickInfo);
end; end;
@ -2117,7 +2112,11 @@ finalization
end. end.
{ {
$Log$ $Log$
Revision 1.146 2004-10-14 14:03:02 mazen Revision 1.147 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.146 2004/10/14 14:03:02 mazen
* Merge is complete for this file, cycles ! * Merge is complete for this file, cycles !
Revision 1.145 2004/10/05 20:21:02 florian Revision 1.145 2004/10/05 20:21:02 florian

View File

@ -70,11 +70,7 @@ uses
systems, systems,
globals, globals,
verbose, verbose,
{$ifdef Delphi}
dmisc;
{$else Delphi}
dos; dos;
{$endif Delphi}
const const
symrelocbufsize = 4096; symrelocbufsize = 4096;
@ -287,7 +283,11 @@ end;
end. end.
{ {
$Log$ $Log$
Revision 1.15 2004-06-20 08:55:30 florian Revision 1.16 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.15 2004/06/20 08:55:30 florian
* logs truncated * logs truncated
Revision 1.14 2004/05/27 18:53:43 peter Revision 1.14 2004/05/27 18:53:43 peter

View File

@ -382,10 +382,8 @@ implementation
var var
olddata : polddata; olddata : polddata;
{$ifdef USEEXCEPT} {$ifdef USEEXCEPT}
{$ifndef Delphi}
recoverpos : jmp_buf; recoverpos : jmp_buf;
oldrecoverpos : pjmp_buf; oldrecoverpos : pjmp_buf;
{$endif Delphi}
{$endif useexcept} {$endif useexcept}
begin begin
inc(compile_level); inc(compile_level);
@ -713,7 +711,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.66 2004-06-20 08:55:30 florian Revision 1.67 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.66 2004/06/20 08:55:30 florian
* logs truncated * logs truncated
Revision 1.65 2004/05/12 13:21:09 karoly Revision 1.65 2004/05/12 13:21:09 karoly

View File

@ -361,7 +361,7 @@ implementation
end; end;
end; end;
recorddef : recorddef :
trecorddef(pd).symtable.foreach_static({$ifdef FPCPROCVAR}@{$endif}resolve_type_forward,nil); trecorddef(pd).symtable.foreach_static(@resolve_type_forward,nil);
objectdef : objectdef :
begin begin
if not(m_fpc in aktmodeswitches) and if not(m_fpc in aktmodeswitches) and
@ -377,7 +377,7 @@ implementation
check objectdefs in objects/records, because these check objectdefs in objects/records, because these
can't exist (anonymous objects aren't allowed) } can't exist (anonymous objects aren't allowed) }
if not(tsym(p).owner.symtabletype in [objectsymtable,recordsymtable]) then if not(tsym(p).owner.symtabletype in [objectsymtable,recordsymtable]) then
tobjectdef(pd).symtable.foreach_static({$ifdef FPCPROCVAR}@{$endif}resolve_type_forward,nil); tobjectdef(pd).symtable.foreach_static(@resolve_type_forward,nil);
end; end;
end; end;
end; end;
@ -557,7 +557,7 @@ implementation
end; end;
until token<>_ID; until token<>_ID;
typecanbeforward:=false; typecanbeforward:=false;
symtablestack.foreach_static({$ifdef FPCPROCVAR}@{$endif}resolve_type_forward,nil); symtablestack.foreach_static(@resolve_type_forward,nil);
block_type:=old_block_type; block_type:=old_block_type;
end; end;
@ -659,7 +659,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.88 2004-09-13 20:33:17 peter Revision 1.89 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.88 2004/09/13 20:33:17 peter
* use realname in error msg * use realname in error msg
Revision 1.87 2004/06/20 08:55:30 florian Revision 1.87 2004/06/20 08:55:30 florian

View File

@ -41,10 +41,6 @@ implementation
node,nld,nmem,ncon,ncnv,ncal, node,nld,nmem,ncon,ncnv,ncal,
scanner, scanner,
pbase,pexpr,pdecsub,pdecvar,ptype pbase,pexpr,pdecsub,pdecvar,ptype
{$ifdef delphi}
,dmisc
,sysutils
{$endif}
; ;
const const
@ -737,7 +733,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.81 2004-08-29 11:28:10 peter Revision 1.82 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.81 2004/08/29 11:28:10 peter
allow published for constructors allow published for constructors
Revision 1.80 2004/08/25 15:57:04 peter Revision 1.80 2004/08/25 15:57:04 peter

View File

@ -62,11 +62,7 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
sysutils,
{$else delphi}
strings, strings,
{$endif delphi}
{ common } { common }
cutils,cclasses, cutils,cclasses,
{ global } { global }
@ -1285,7 +1281,7 @@ const
( (
idtok:_ABSTRACT; idtok:_ABSTRACT;
pd_flags : [pd_interface,pd_object,pd_notobjintf]; pd_flags : [pd_interface,pd_object,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_abstract; handler : @pd_abstract;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_abstractmethod]; pooption : [po_abstractmethod];
mutexclpocall : [pocall_internproc,pocall_inline]; mutexclpocall : [pocall_internproc,pocall_inline];
@ -1294,7 +1290,7 @@ const
),( ),(
idtok:_ALIAS; idtok:_ALIAS;
pd_flags : [pd_implemen,pd_body,pd_notobjintf]; pd_flags : [pd_implemen,pd_body,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_alias; handler : @pd_alias;
pocall : pocall_none; pocall : pocall_none;
pooption : []; pooption : [];
mutexclpocall : [pocall_inline]; mutexclpocall : [pocall_inline];
@ -1303,7 +1299,7 @@ const
),( ),(
idtok:_ASMNAME; idtok:_ASMNAME;
pd_flags : [pd_interface,pd_implemen,pd_notobjintf]; pd_flags : [pd_interface,pd_implemen,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_asmname; handler : @pd_asmname;
pocall : pocall_cdecl; pocall : pocall_cdecl;
pooption : [po_external]; pooption : [po_external];
mutexclpocall : [pocall_internproc,pocall_inline]; mutexclpocall : [pocall_internproc,pocall_inline];
@ -1339,7 +1335,7 @@ const
),( ),(
idtok:_DYNAMIC; idtok:_DYNAMIC;
pd_flags : [pd_interface,pd_object,pd_notobjintf]; pd_flags : [pd_interface,pd_object,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_virtual; handler : @pd_virtual;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_virtualmethod]; pooption : [po_virtualmethod];
mutexclpocall : [pocall_internproc,pocall_inline]; mutexclpocall : [pocall_internproc,pocall_inline];
@ -1348,7 +1344,7 @@ const
),( ),(
idtok:_EXPORT; idtok:_EXPORT;
pd_flags : [pd_body,pd_interface,pd_implemen,pd_notobjintf]; pd_flags : [pd_body,pd_interface,pd_implemen,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_export; handler : @pd_export;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_exports,po_public]; pooption : [po_exports,po_public];
mutexclpocall : [pocall_internproc,pocall_inline]; mutexclpocall : [pocall_internproc,pocall_inline];
@ -1357,7 +1353,7 @@ const
),( ),(
idtok:_EXTERNAL; idtok:_EXTERNAL;
pd_flags : [pd_implemen,pd_interface,pd_notobject,pd_notobjintf]; pd_flags : [pd_implemen,pd_interface,pd_notobject,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_external; handler : @pd_external;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_external]; pooption : [po_external];
mutexclpocall : [pocall_internproc,pocall_inline,pocall_syscall]; mutexclpocall : [pocall_internproc,pocall_inline,pocall_syscall];
@ -1366,7 +1362,7 @@ const
),( ),(
idtok:_FAR; idtok:_FAR;
pd_flags : [pd_implemen,pd_body,pd_interface,pd_procvar,pd_notobject,pd_notobjintf]; pd_flags : [pd_implemen,pd_body,pd_interface,pd_procvar,pd_notobject,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_far; handler : @pd_far;
pocall : pocall_none; pocall : pocall_none;
pooption : []; pooption : [];
mutexclpocall : [pocall_internproc,pocall_inline]; mutexclpocall : [pocall_internproc,pocall_inline];
@ -1384,7 +1380,7 @@ const
),( ),(
idtok:_FORWARD; idtok:_FORWARD;
pd_flags : [pd_implemen,pd_notobject,pd_notobjintf]; pd_flags : [pd_implemen,pd_notobject,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_forward; handler : @pd_forward;
pocall : pocall_none; pocall : pocall_none;
pooption : []; pooption : [];
mutexclpocall : [pocall_internproc,pocall_inline]; mutexclpocall : [pocall_internproc,pocall_inline];
@ -1402,7 +1398,7 @@ const
),( ),(
idtok:_INLINE; idtok:_INLINE;
pd_flags : [pd_interface,pd_implemen,pd_body,pd_notobjintf]; pd_flags : [pd_interface,pd_implemen,pd_body,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_inline; handler : @pd_inline;
pocall : pocall_inline; pocall : pocall_inline;
pooption : []; pooption : [];
mutexclpocall : []; mutexclpocall : [];
@ -1411,7 +1407,7 @@ const
),( ),(
idtok:_INTERNCONST; idtok:_INTERNCONST;
pd_flags : [pd_implemen,pd_body,pd_notobject,pd_notobjintf]; pd_flags : [pd_implemen,pd_body,pd_notobject,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_intern; handler : @pd_intern;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_internconst]; pooption : [po_internconst];
mutexclpocall : []; mutexclpocall : [];
@ -1420,7 +1416,7 @@ const
),( ),(
idtok:_INTERNPROC; idtok:_INTERNPROC;
pd_flags : [pd_implemen,pd_notobject,pd_notobjintf]; pd_flags : [pd_implemen,pd_notobject,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_intern; handler : @pd_intern;
pocall : pocall_internproc; pocall : pocall_internproc;
pooption : []; pooption : [];
mutexclpocall : []; mutexclpocall : [];
@ -1429,7 +1425,7 @@ const
),( ),(
idtok:_INTERRUPT; idtok:_INTERRUPT;
pd_flags : [pd_implemen,pd_body,pd_notobject,pd_notobjintf]; pd_flags : [pd_implemen,pd_body,pd_notobject,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_interrupt; handler : @pd_interrupt;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_interrupt]; pooption : [po_interrupt];
mutexclpocall : [pocall_internproc,pocall_cdecl,pocall_cppdecl,pocall_stdcall, mutexclpocall : [pocall_internproc,pocall_cdecl,pocall_cppdecl,pocall_stdcall,
@ -1448,7 +1444,7 @@ const
),( ),(
idtok:_MESSAGE; idtok:_MESSAGE;
pd_flags : [pd_interface,pd_object,pd_notobjintf]; pd_flags : [pd_interface,pd_object,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_message; handler : @pd_message;
pocall : pocall_none; pocall : pocall_none;
pooption : []; { can be po_msgstr or po_msgint } pooption : []; { can be po_msgstr or po_msgint }
mutexclpocall : [pocall_inline,pocall_internproc]; mutexclpocall : [pocall_inline,pocall_internproc];
@ -1457,7 +1453,7 @@ const
),( ),(
idtok:_NEAR; idtok:_NEAR;
pd_flags : [pd_implemen,pd_body,pd_procvar,pd_notobjintf]; pd_flags : [pd_implemen,pd_body,pd_procvar,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_near; handler : @pd_near;
pocall : pocall_none; pocall : pocall_none;
pooption : []; pooption : [];
mutexclpocall : [pocall_internproc]; mutexclpocall : [pocall_internproc];
@ -1475,7 +1471,7 @@ const
),( ),(
idtok:_OVERLOAD; idtok:_OVERLOAD;
pd_flags : [pd_implemen,pd_interface,pd_body]; pd_flags : [pd_implemen,pd_interface,pd_body];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_overload; handler : @pd_overload;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_overload]; pooption : [po_overload];
mutexclpocall : [pocall_internproc]; mutexclpocall : [pocall_internproc];
@ -1484,7 +1480,7 @@ const
),( ),(
idtok:_OVERRIDE; idtok:_OVERRIDE;
pd_flags : [pd_interface,pd_object,pd_notobjintf]; pd_flags : [pd_interface,pd_object,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_override; handler : @pd_override;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_overridingmethod,po_virtualmethod]; pooption : [po_overridingmethod,po_virtualmethod];
mutexclpocall : [pocall_inline,pocall_internproc]; mutexclpocall : [pocall_inline,pocall_internproc];
@ -1520,7 +1516,7 @@ const
),( ),(
idtok:_REINTRODUCE; idtok:_REINTRODUCE;
pd_flags : [pd_interface,pd_object,pd_notobjintf]; pd_flags : [pd_interface,pd_object,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_reintroduce; handler : @pd_reintroduce;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_reintroduce]; pooption : [po_reintroduce];
mutexclpocall : [pocall_inline,pocall_internproc]; mutexclpocall : [pocall_inline,pocall_internproc];
@ -1558,7 +1554,7 @@ const
),( ),(
idtok:_STATIC; idtok:_STATIC;
pd_flags : [pd_interface,pd_object,pd_notobjintf]; pd_flags : [pd_interface,pd_object,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_static; handler : @pd_static;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_staticmethod]; pooption : [po_staticmethod];
mutexclpocall : [pocall_inline,pocall_internproc]; mutexclpocall : [pocall_inline,pocall_internproc];
@ -1576,7 +1572,7 @@ const
),( ),(
idtok:_SYSCALL; idtok:_SYSCALL;
pd_flags : [pd_interface,pd_implemen,pd_notobject,pd_notobjintf]; pd_flags : [pd_interface,pd_implemen,pd_notobject,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_syscall; handler : @pd_syscall;
pocall : pocall_syscall; pocall : pocall_syscall;
pooption : []; pooption : [];
mutexclpocall : []; mutexclpocall : [];
@ -1585,7 +1581,7 @@ const
),( ),(
idtok:_VIRTUAL; idtok:_VIRTUAL;
pd_flags : [pd_interface,pd_object,pd_notobjintf]; pd_flags : [pd_interface,pd_object,pd_notobjintf];
handler : {$ifdef FPCPROCVAR}@{$endif}pd_virtual; handler : @pd_virtual;
pocall : pocall_none; pocall : pocall_none;
pooption : [po_virtualmethod]; pooption : [po_virtualmethod];
mutexclpocall : [pocall_inline,pocall_internproc]; mutexclpocall : [pocall_inline,pocall_internproc];
@ -1809,7 +1805,7 @@ const
tprocdef(pd).setmangledname(target_info.Cprefix+tprocdef(pd).procsym.realname); tprocdef(pd).setmangledname(target_info.Cprefix+tprocdef(pd).procsym.realname);
end; end;
{ check C cdecl para types } { check C cdecl para types }
pd.parast.foreach_static({$ifdef FPCPROCVAR}@{$endif}check_c_para,nil); pd.parast.foreach_static(@check_c_para,nil);
end; end;
end; end;
pocall_cppdecl : pocall_cppdecl :
@ -1820,7 +1816,7 @@ const
if not tprocdef(pd).has_mangledname then if not tprocdef(pd).has_mangledname then
tprocdef(pd).setmangledname(target_info.Cprefix+tprocdef(pd).cplusplusmangledname); tprocdef(pd).setmangledname(target_info.Cprefix+tprocdef(pd).cplusplusmangledname);
{ check C cdecl para types } { check C cdecl para types }
pd.parast.foreach_static({$ifdef FPCPROCVAR}@{$endif}check_c_para,nil); pd.parast.foreach_static(@check_c_para,nil);
end; end;
end; end;
pocall_compilerproc : pocall_compilerproc :
@ -1872,7 +1868,7 @@ const
{ Make var parameters regable, this must be done after the calling { Make var parameters regable, this must be done after the calling
convention is set. } convention is set. }
pd.parast.foreach_static({$ifdef FPCPROCVAR}@{$endif}set_addr_param_regable,pd); pd.parast.foreach_static(@set_addr_param_regable,pd);
{ add mangledname to external list } { add mangledname to external list }
if (pd.deftype=procdef) and if (pd.deftype=procdef) and
@ -2270,7 +2266,11 @@ const
end. end.
{ {
$Log$ $Log$
Revision 1.193 2004-10-11 15:45:35 peter Revision 1.194 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.193 2004/10/11 15:45:35 peter
* mark non-regable after calling convention is set * mark non-regable after calling convention is set
Revision 1.192 2004/10/10 21:08:55 peter Revision 1.192 2004/10/10 21:08:55 peter

View File

@ -56,10 +56,6 @@ implementation
pbase,pexpr,ptype,ptconst,pdecsub, pbase,pexpr,ptype,ptconst,pdecsub,
{ link } { link }
import import
{$ifdef Delphi}
,dmisc
,sysutils
{$endif}
; ;
@ -1288,7 +1284,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.80 2004-10-12 14:36:38 peter Revision 1.81 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.80 2004/10/12 14:36:38 peter
* gen high tree makes copy in temp when there is a calln * gen high tree makes copy in temp when there is a calln
Revision 1.79 2004/08/17 16:29:21 jonas Revision 1.79 2004/08/17 16:29:21 jonas

View File

@ -48,10 +48,6 @@ implementation
pbase,pexpr, pbase,pexpr,
{ link } { link }
gendef,export gendef,export
{$ifdef Delphi}
,dmisc
,sysutils
{$endif}
; ;
@ -186,7 +182,11 @@ end.
{ {
$Log$ $Log$
Revision 1.28 2004-06-20 08:55:30 florian Revision 1.29 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.28 2004/06/20 08:55:30 florian
* logs truncated * logs truncated
Revision 1.27 2004/06/16 20:07:09 florian Revision 1.27 2004/06/16 20:07:09 florian

View File

@ -62,9 +62,6 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
SysUtils,
{$endif}
{ common } { common }
cutils, cutils,
{ global } { global }
@ -2481,7 +2478,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.165 2004-10-12 19:51:13 peter Revision 1.166 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.165 2004/10/12 19:51:13 peter
* all checking for visibility is now done by is_visible_for_object * all checking for visibility is now done by is_visible_for_object
Revision 1.164 2004/10/12 14:35:47 peter Revision 1.164 2004/10/12 14:35:47 peter

View File

@ -44,9 +44,6 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
SysUtils,
{$endif}
{ common } { common }
cutils, cutils,
{ global } { global }
@ -759,7 +756,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.32 2004-06-20 08:55:30 florian Revision 1.33 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.32 2004/06/20 08:55:30 florian
* logs truncated * logs truncated
Revision 1.31 2004/05/23 18:28:41 peter Revision 1.31 2004/05/23 18:28:41 peter

View File

@ -247,8 +247,8 @@ implementation
begin begin
ltvTable:=TAAsmoutput.create; ltvTable:=TAAsmoutput.create;
if assigned(current_module.globalsymtable) then if assigned(current_module.globalsymtable) then
current_module.globalsymtable.foreach_static({$ifdef FPCPROCVAR}@{$endif}AddToThreadvarList,ltvTable); current_module.globalsymtable.foreach_static(@AddToThreadvarList,ltvTable);
current_module.localsymtable.foreach_static({$ifdef FPCPROCVAR}@{$endif}AddToThreadvarList,ltvTable); current_module.localsymtable.foreach_static(@AddToThreadvarList,ltvTable);
if ltvTable.first<>nil then if ltvTable.first<>nil then
begin begin
s:=make_mangledname('THREADVARLIST',current_module.localsymtable,''); s:=make_mangledname('THREADVARLIST',current_module.localsymtable,'');
@ -1564,7 +1564,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.165 2004-10-04 18:26:51 peter Revision 1.166 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.165 2004/10/04 18:26:51 peter
* debuginfo fixes * debuginfo fixes
Revision 1.164 2004/09/14 16:33:46 peter Revision 1.164 2004/09/14 16:33:46 peter

File diff suppressed because it is too large Load Diff

View File

@ -150,8 +150,8 @@ implementation
SetExtraInfoString({$ifdef FPC}@{$endif}get_extra_info); SetExtraInfoString({$ifdef FPC}@{$endif}get_extra_info);
{$else} {$else}
SetHeapExtraInfo(sizeof(textra_info), SetHeapExtraInfo(sizeof(textra_info),
{$ifdef FPCPROCVAR}@{$endif}set_extra_info, set_extra_info,
{$ifdef FPCPROCVAR}@{$endif}show_extra_info); show_extra_info);
{$endif} {$endif}
end; end;
pp_heap_inited:=true; pp_heap_inited:=true;
@ -163,7 +163,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.13 2004-06-20 08:55:30 florian Revision 1.14 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.13 2004/06/20 08:55:30 florian
* logs truncated * logs truncated
} }

View File

@ -589,7 +589,7 @@ implementation
end; end;
end; end;
if try_to_consume(_COMMA) then if try_to_consume(_COMMA) then
right:=_with_statement{$ifdef FPCPROCVAR}(){$endif} right:=_with_statement
else else
begin begin
consume(_DO); consume(_DO);
@ -620,7 +620,7 @@ implementation
{ try to recover from error } { try to recover from error }
if try_to_consume(_COMMA) then if try_to_consume(_COMMA) then
begin begin
hp:=_with_statement{$ifdef FPCPROCVAR}(){$endif}; hp:=_with_statement;
if (hp=nil) then; { remove warning about unused } if (hp=nil) then; { remove warning about unused }
end end
else else
@ -1055,7 +1055,7 @@ implementation
if token in endtokens then if token in endtokens then
tlabelnode(p).left:=cnothingnode.create tlabelnode(p).left:=cnothingnode.create
else else
tlabelnode(p).left:=statement{$ifdef FPCPROCVAR}(){$endif}; tlabelnode(p).left:=statement;
{ be sure to have left also resulttypepass } { be sure to have left also resulttypepass }
resulttypepass(tlabelnode(p).left); resulttypepass(tlabelnode(p).left);
end end
@ -1173,8 +1173,8 @@ implementation
(vm, i386, vm only currently) (vm, i386, vm only currently)
} }
locals:=0; locals:=0;
current_procinfo.procdef.localst.foreach_static({$ifdef FPCPROCVAR}@{$endif}count_locals,@locals); current_procinfo.procdef.localst.foreach_static(@count_locals,@locals);
current_procinfo.procdef.parast.foreach_static({$ifdef FPCPROCVAR}@{$endif}count_locals,@locals); current_procinfo.procdef.parast.foreach_static(@count_locals,@locals);
if (locals=0) and if (locals=0) and
(current_procinfo.procdef.owner.symtabletype<>objectsymtable) and (current_procinfo.procdef.owner.symtabletype<>objectsymtable) and
(not assigned(current_procinfo.procdef.funcretsym) or (not assigned(current_procinfo.procdef.funcretsym) or
@ -1206,7 +1206,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.141 2004-09-27 15:15:52 peter Revision 1.142 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.141 2004/09/27 15:15:52 peter
* register loopvarsym for fields instead of record variable * register loopvarsym for fields instead of record variable
* don't allow class fields as loop var * don't allow class fields as loop var

View File

@ -226,7 +226,7 @@ implementation
begin begin
block:=statement_block(_BEGIN); block:=statement_block(_BEGIN);
if symtablestack.symtabletype=localsymtable then if symtablestack.symtabletype=localsymtable then
symtablestack.foreach_static({$ifdef FPCPROCVAR}@{$endif}initializevars,block); symtablestack.foreach_static(@initializevars,block);
end; end;
end; end;
@ -643,8 +643,8 @@ implementation
cg.t_times:=100; cg.t_times:=100;
{ clear register count } { clear register count }
symtablestack.foreach_static({$ifdef FPCPROCVAR}@{$endif}clearrefs,nil); symtablestack.foreach_static(@clearrefs,nil);
symtablestack.next.foreach_static({$ifdef FPCPROCVAR}@{$endif}clearrefs,nil); symtablestack.next.foreach_static(@clearrefs,nil);
{ there's always a call to FPC_INITIALIZEUNITS/FPC_DO_EXIT in the main program } { there's always a call to FPC_INITIALIZEUNITS/FPC_DO_EXIT in the main program }
if (procdef.localst.symtablelevel=main_program_level) and if (procdef.localst.symtablelevel=main_program_level) and
@ -652,8 +652,8 @@ implementation
include(flags,pi_do_call); include(flags,pi_do_call);
{ set implicit_finally flag when there are locals/paras to be finalized } { set implicit_finally flag when there are locals/paras to be finalized }
current_procinfo.procdef.parast.foreach_static({$ifdef FPCPROCVAR}@{$endif}check_finalize_paras,nil); current_procinfo.procdef.parast.foreach_static(@check_finalize_paras,nil);
current_procinfo.procdef.localst.foreach_static({$ifdef FPCPROCVAR}@{$endif}check_finalize_locals,nil); current_procinfo.procdef.localst.foreach_static(@check_finalize_locals,nil);
{ firstpass everything } { firstpass everything }
flowcontrol:=[]; flowcontrol:=[];
@ -956,7 +956,7 @@ implementation
paraitem := tparaitem(paraitem.next); paraitem := tparaitem(paraitem.next);
end; end;
{ we currently can't handle exit-statements (would exit the caller) } { we currently can't handle exit-statements (would exit the caller) }
result := not foreachnodestatic(procdef.inlininginfo^.code,{$ifdef FPCPROCVAR}@{$endif}containsforbiddennode,nil); result := not foreachnodestatic(procdef.inlininginfo^.code,@containsforbiddennode,nil);
end; end;
@ -1214,7 +1214,7 @@ implementation
{ check if there are para's which require initing -> set } { check if there are para's which require initing -> set }
{ pi_do_call (if not yet set) } { pi_do_call (if not yet set) }
if not(pi_do_call in current_procinfo.flags) then if not(pi_do_call in current_procinfo.flags) then
pd.parast.foreach_static({$ifdef FPCPROCVAR}@{$endif}check_init_paras,nil); pd.parast.foreach_static(@check_init_paras,nil);
{ set _FAIL as keyword if constructor } { set _FAIL as keyword if constructor }
if (pd.proctypeoption=potype_constructor) then if (pd.proctypeoption=potype_constructor) then
@ -1343,7 +1343,7 @@ implementation
{ check for incomplete class definitions, this is only required { check for incomplete class definitions, this is only required
for fpc modes } for fpc modes }
if (m_fpc in aktmodeswitches) then if (m_fpc in aktmodeswitches) then
symtablestack.foreach_static({$ifdef FPCPROCVAR}@{$endif}check_forward_class,nil); symtablestack.foreach_static(@check_forward_class,nil);
end; end;
@ -1384,14 +1384,18 @@ implementation
{ check for incomplete class definitions, this is only required { check for incomplete class definitions, this is only required
for fpc modes } for fpc modes }
if (m_fpc in aktmodeswitches) then if (m_fpc in aktmodeswitches) then
symtablestack.foreach_static({$ifdef FPCPROCVAR}@{$endif}check_forward_class,nil); symtablestack.foreach_static(@check_forward_class,nil);
end; end;
end. end.
{ {
$Log$ $Log$
Revision 1.208 2004-10-10 20:22:53 peter Revision 1.209 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.208 2004/10/10 20:22:53 peter
* symtable allocation rewritten * symtable allocation rewritten
* loading of parameters to local temps/regs cleanup * loading of parameters to local temps/regs cleanup
* regvar support for parameters * regvar support for parameters

View File

@ -49,10 +49,6 @@ implementation
gdb, gdb,
{$endif GDB} {$endif GDB}
node,nbas,nflw,nset,ncon,ncnv,nld,nmem,ncal,nmat,nadd,ninl,nopt node,nbas,nflw,nset,ncon,ncnv,nld,nmem,ncal,nmat,nadd,ninl,nopt
{$ifdef Delphi}
,dmisc
,sysutils
{$endif}
; ;
@ -538,7 +534,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.71 2004-07-05 21:49:43 olle Revision 1.72 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.71 2004/07/05 21:49:43 olle
+ macpas style: exit, cycle, leave + macpas style: exit, cycle, leave
+ macpas compiler directive: PUSH POP + macpas compiler directive: PUSH POP

View File

@ -36,11 +36,7 @@ interface
implementation implementation
uses uses
{$ifdef Delphi}
sysutils,
{$else}
strings, strings,
{$endif Delphi}
globtype,systems,tokens,verbose, globtype,systems,tokens,verbose,
cutils,globals,widestr,scanner, cutils,globals,widestr,scanner,
symconst,symbase,symdef,symtable, symconst,symbase,symdef,symtable,
@ -1091,7 +1087,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.91 2004-07-12 17:58:19 peter Revision 1.92 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.91 2004/07/12 17:58:19 peter
* remove maxlen field from ansistring/widestrings * remove maxlen field from ansistring/widestrings
Revision 1.90 2004/07/03 14:06:35 daniel Revision 1.90 2004/07/03 14:06:35 daniel

View File

@ -215,11 +215,7 @@ Function SearchIConstant(const s:string; var l:aint): boolean;
Implementation Implementation
uses uses
{$ifdef delphi}
sysutils,
{$else}
strings, strings,
{$endif}
defutil,systems,verbose,globals, defutil,systems,verbose,globals,
symtable,paramgr, symtable,paramgr,
aasmcpu, aasmcpu,
@ -1192,7 +1188,7 @@ end;
procedure TLocalLabelList.CheckEmitted; procedure TLocalLabelList.CheckEmitted;
begin begin
ForEach_Static({$ifdef FPCPROCVAR}@{$endif}LocalLabelEmitted,nil) ForEach_Static(@LocalLabelEmitted,nil)
end; end;
@ -1668,7 +1664,11 @@ end;
end. end.
{ {
$Log$ $Log$
Revision 1.90 2004-10-08 17:09:43 peter Revision 1.91 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.90 2004/10/08 17:09:43 peter
* tvarsym.varregable added, split vo_regable from varoptions * tvarsym.varregable added, split vo_regable from varoptions
Revision 1.89 2004/09/27 15:14:34 peter Revision 1.89 2004/09/27 15:14:34 peter

View File

@ -160,10 +160,10 @@ implementation
if (p.registersint<maxvarregs) then if (p.registersint<maxvarregs) then
begin begin
parasym:=false; parasym:=false;
symtablestack.foreach_static({$ifdef FPCPROCVAR}@{$endif}searchregvars,@parasym); symtablestack.foreach_static(searchregvars,@parasym);
{ copy parameter into a register ? } { copy parameter into a register ? }
parasym:=true; parasym:=true;
symtablestack.next.foreach_static({$ifdef FPCPROCVAR}@{$endif}searchregvars,@parasym); symtablestack.next.foreach_static(searchregvars,@parasym);
{ hold needed registers free } { hold needed registers free }
for i:=maxvarregs downto maxvarregs-p.registersint+1 do for i:=maxvarregs downto maxvarregs-p.registersint+1 do
begin begin
@ -215,7 +215,7 @@ implementation
if ((p.registersfpu+1)<maxfpuvarregs) then if ((p.registersfpu+1)<maxfpuvarregs) then
begin begin
parasym:=false; parasym:=false;
symtablestack.foreach_static({$ifdef FPCPROCVAR}@{$endif}searchfpuregvars,@parasym); symtablestack.foreach_static(searchfpuregvars,@parasym);
{$ifndef i386} {$ifndef i386}
{ this code should be never enabled because } { this code should be never enabled because }
{ 1. the caller loads parameters into registers } { 1. the caller loads parameters into registers }
@ -224,7 +224,7 @@ implementation
{ (FK) } { (FK) }
{ copy parameter into a register ? } { copy parameter into a register ? }
parasym:=true; parasym:=true;
symtablestack.next.foreach_static({$ifdef FPCPROCVAR}@{$endif}searchregvars,@parasym); symtablestack.next.foreach_static(searchregvars,@parasym);
{$endif i386} {$endif i386}
{ hold needed registers free } { hold needed registers free }
@ -669,7 +669,11 @@ end.
{ {
$Log$ $Log$
Revision 1.80 2004-09-26 17:45:30 peter Revision 1.81 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.80 2004/09/26 17:45:30 peter
* simple regvar support, not yet finished * simple regvar support, not yet finished
Revision 1.79 2004/09/25 14:23:54 peter Revision 1.79 2004/09/25 14:23:54 peter

View File

@ -34,9 +34,6 @@ unit rgobj;
cutils, cpubase, cutils, cpubase,
aasmbase,aasmtai,aasmcpu, aasmbase,aasmtai,aasmcpu,
cclasses,globtype,cgbase,node, cclasses,globtype,cgbase,node,
{$ifdef delphi}
dmisc,
{$endif}
cpuinfo cpuinfo
; ;
@ -1995,7 +1992,11 @@ unit rgobj;
end. end.
{ {
$Log$ $Log$
Revision 1.142 2004-10-13 21:12:51 peter Revision 1.143 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.142 2004/10/13 21:12:51 peter
* -Or fixes for open array * -Or fixes for open array
Revision 1.141 2004/10/11 15:47:03 peter Revision 1.141 2004/10/11 15:47:03 peter

View File

@ -1024,90 +1024,90 @@ implementation
procedure InitScannerDirectives; procedure InitScannerDirectives;
begin begin
AddDirective('ALIGN',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_align); AddDirective('ALIGN',directive_all, @dir_align);
{$ifdef m68k} {$ifdef m68k}
AddDirective('APPID',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_appid); AddDirective('APPID',directive_all, @dir_appid);
AddDirective('APPNAME',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_appname); AddDirective('APPNAME',directive_all, @dir_appname);
{$endif m68k} {$endif m68k}
AddDirective('APPTYPE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_apptype); AddDirective('APPTYPE',directive_all, @dir_apptype);
AddDirective('ASMMODE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_asmmode); AddDirective('ASMMODE',directive_all, @dir_asmmode);
AddDirective('ASSERTIONS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_assertions); AddDirective('ASSERTIONS',directive_all, @dir_assertions);
AddDirective('BOOLEVAL',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_booleval); AddDirective('BOOLEVAL',directive_all, @dir_booleval);
AddDirective('CALLING',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_calling); AddDirective('CALLING',directive_all, @dir_calling);
AddDirective('CODEPAGE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_codepage); AddDirective('CODEPAGE',directive_all, @dir_codepage);
AddDirective('COPYRIGHT',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_copyright); AddDirective('COPYRIGHT',directive_all, @dir_copyright);
AddDirective('D',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_description); AddDirective('D',directive_all, @dir_description);
AddDirective('DEBUGINFO',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_debuginfo); AddDirective('DEBUGINFO',directive_all, @dir_debuginfo);
AddDirective('DESCRIPTION',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_description); AddDirective('DESCRIPTION',directive_all, @dir_description);
AddDirective('ERROR',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_error); AddDirective('ERROR',directive_all, @dir_error);
AddDirective('ERRORC',directive_mac, {$ifdef FPCPROCVAR}@{$endif}dir_error); AddDirective('ERRORC',directive_mac, @dir_error);
AddDirective('EXTENDEDSYNTAX',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_extendedsyntax); AddDirective('EXTENDEDSYNTAX',directive_all, @dir_extendedsyntax);
AddDirective('EXTERNALSYM',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_externalsym); AddDirective('EXTERNALSYM',directive_all, @dir_externalsym);
AddDirective('FATAL',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_fatal); AddDirective('FATAL',directive_all, @dir_fatal);
AddDirective('FPUTYPE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_fputype); AddDirective('FPUTYPE',directive_all, @dir_fputype);
AddDirective('GOTO',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_goto); AddDirective('GOTO',directive_all, @dir_goto);
AddDirective('HINT',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_hint); AddDirective('HINT',directive_all, @dir_hint);
AddDirective('HINTS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_hints); AddDirective('HINTS',directive_all, @dir_hints);
AddDirective('IOCHECKS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_iochecks); AddDirective('IOCHECKS',directive_all, @dir_iochecks);
AddDirective('IMPLICITEXCEPTIONS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_implicitexceptions); AddDirective('IMPLICITEXCEPTIONS',directive_all, @dir_implicitexceptions);
AddDirective('INCLUDEPATH',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_includepath); AddDirective('INCLUDEPATH',directive_all, @dir_includepath);
AddDirective('INFO',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_info); AddDirective('INFO',directive_all, @dir_info);
AddDirective('INLINE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_inline); AddDirective('INLINE',directive_all, @dir_inline);
AddDirective('INTERFACES',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_interfaces); AddDirective('INTERFACES',directive_all, @dir_interfaces);
AddDirective('L',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_link); AddDirective('L',directive_all, @dir_link);
AddDirective('LIBEXPORT',directive_mac, {$ifdef FPCPROCVAR}@{$endif}dir_libexport); AddDirective('LIBEXPORT',directive_mac, @dir_libexport);
AddDirective('LIBRARYPATH',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_librarypath); AddDirective('LIBRARYPATH',directive_all, @dir_librarypath);
AddDirective('LINK',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_link); AddDirective('LINK',directive_all, @dir_link);
AddDirective('LINKLIB',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_linklib); AddDirective('LINKLIB',directive_all, @dir_linklib);
AddDirective('LOCALSYMBOLS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_localsymbols); AddDirective('LOCALSYMBOLS',directive_all, @dir_localsymbols);
AddDirective('LONGSTRINGS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_longstrings); AddDirective('LONGSTRINGS',directive_all, @dir_longstrings);
AddDirective('M',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_memory); AddDirective('M',directive_all, @dir_memory);
AddDirective('MACRO',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_macro); AddDirective('MACRO',directive_all, @dir_macro);
AddDirective('MAXFPUREGISTERS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_maxfpuregisters); AddDirective('MAXFPUREGISTERS',directive_all, @dir_maxfpuregisters);
AddDirective('MEMORY',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_memory); AddDirective('MEMORY',directive_all, @dir_memory);
AddDirective('MESSAGE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_message); AddDirective('MESSAGE',directive_all, @dir_message);
AddDirective('MINENUMSIZE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_packenum); AddDirective('MINENUMSIZE',directive_all, @dir_packenum);
AddDirective('MMX',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_mmx); AddDirective('MMX',directive_all, @dir_mmx);
AddDirective('MODE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_mode); AddDirective('MODE',directive_all, @dir_mode);
AddDirective('NOTE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_note); AddDirective('NOTE',directive_all, @dir_note);
AddDirective('NOTES',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_notes); AddDirective('NOTES',directive_all, @dir_notes);
AddDirective('OBJECTCHECKS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_objectchecks); AddDirective('OBJECTCHECKS',directive_all, @dir_objectchecks);
AddDirective('OBJECTPATH',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_objectpath); AddDirective('OBJECTPATH',directive_all, @dir_objectpath);
AddDirective('OPENSTRINGS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_openstrings); AddDirective('OPENSTRINGS',directive_all, @dir_openstrings);
AddDirective('OUTPUT_FORMAT',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_output_format); AddDirective('OUTPUT_FORMAT',directive_all, @dir_output_format);
AddDirective('OVERFLOWCHECKS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_overflowchecks); AddDirective('OVERFLOWCHECKS',directive_all, @dir_overflowchecks);
AddDirective('PACKENUM',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_packenum); AddDirective('PACKENUM',directive_all, @dir_packenum);
AddDirective('PACKRECORDS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_packrecords); AddDirective('PACKRECORDS',directive_all, @dir_packrecords);
{$IFDEF TestVarsets} {$IFDEF TestVarsets}
AddDirective('PACKSET',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_packset); AddDirective('PACKSET',directive_all, @dir_packset);
{$ENDIF} {$ENDIF}
AddDirective('POP',directive_mac, {$ifdef FPCPROCVAR}@{$endif}dir_pop); AddDirective('POP',directive_mac, @dir_pop);
AddDirective('PROFILE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_profile); AddDirective('PROFILE',directive_all, @dir_profile);
AddDirective('PUSH',directive_mac, {$ifdef FPCPROCVAR}@{$endif}dir_push); AddDirective('PUSH',directive_mac, @dir_push);
AddDirective('R',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_resource); AddDirective('R',directive_all, @dir_resource);
AddDirective('RANGECHECKS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_rangechecks); AddDirective('RANGECHECKS',directive_all, @dir_rangechecks);
AddDirective('REFERENCEINFO',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_referenceinfo); AddDirective('REFERENCEINFO',directive_all, @dir_referenceinfo);
AddDirective('RESOURCE',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_resource); AddDirective('RESOURCE',directive_all, @dir_resource);
AddDirective('SATURATION',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_saturation); AddDirective('SATURATION',directive_all, @dir_saturation);
AddDirective('SCREENNAME',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_screenname); AddDirective('SCREENNAME',directive_all, @dir_screenname);
AddDirective('SMARTLINK',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_smartlink); AddDirective('SMARTLINK',directive_all, @dir_smartlink);
AddDirective('STACKFRAMES',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_stackframes); AddDirective('STACKFRAMES',directive_all, @dir_stackframes);
AddDirective('STATIC',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_static); AddDirective('STATIC',directive_all, @dir_static);
AddDirective('STOP',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_stop); AddDirective('STOP',directive_all, @dir_stop);
AddDirective('THREADING',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_threading); AddDirective('THREADING',directive_all, @dir_threading);
AddDirective('THREADNAME',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_threadname); AddDirective('THREADNAME',directive_all, @dir_threadname);
AddDirective('TYPEDADDRESS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_typedaddress); AddDirective('TYPEDADDRESS',directive_all, @dir_typedaddress);
AddDirective('TYPEINFO',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_typeinfo); AddDirective('TYPEINFO',directive_all, @dir_typeinfo);
AddDirective('UNITPATH',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_unitpath); AddDirective('UNITPATH',directive_all, @dir_unitpath);
AddDirective('VARSTRINGCHECKS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_varstringchecks); AddDirective('VARSTRINGCHECKS',directive_all, @dir_varstringchecks);
AddDirective('VERSION',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_version); AddDirective('VERSION',directive_all, @dir_version);
AddDirective('WAIT',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_wait); AddDirective('WAIT',directive_all, @dir_wait);
AddDirective('WARNING',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_warning); AddDirective('WARNING',directive_all, @dir_warning);
AddDirective('WARNINGS',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_warnings); AddDirective('WARNINGS',directive_all, @dir_warnings);
AddDirective('WRITEABLECONST',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_writeableconst); AddDirective('WRITEABLECONST',directive_all, @dir_writeableconst);
AddDirective('Z1',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_z1); AddDirective('Z1',directive_all, @dir_z1);
AddDirective('Z2',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_z2); AddDirective('Z2',directive_all, @dir_z2);
AddDirective('Z4',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_z4); AddDirective('Z4',directive_all, @dir_z4);
end; end;
begin begin
@ -1115,7 +1115,11 @@ begin
end. end.
{ {
$Log$ $Log$
Revision 1.43 2004-09-04 21:18:47 armin Revision 1.44 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.43 2004/09/04 21:18:47 armin
* target netwlibc added (libc is preferred for newer netware versions) * target netwlibc added (libc is preferred for newer netware versions)
Revision 1.42 2004/08/31 22:07:04 olle Revision 1.42 2004/08/31 22:07:04 olle

View File

@ -203,11 +203,7 @@ interface
implementation implementation
uses uses
{$ifdef delphi}
dmisc,
{$else}
dos, dos,
{$endif delphi}
cutils, cutils,
systems, systems,
switches, switches,
@ -1683,7 +1679,7 @@ implementation
oldaktfilepos:=aktfilepos; oldaktfilepos:=aktfilepos;
repeat repeat
current_scanner.gettokenpos; current_scanner.gettokenpos;
p.proc{$ifdef FPCPROCVAR}(){$endif}; p.proc;
{ accept the text ? } { accept the text ? }
if (current_scanner.preprocstack=nil) or current_scanner.preprocstack.accept then if (current_scanner.preprocstack=nil) or current_scanner.preprocstack.accept then
break break
@ -1780,7 +1776,7 @@ implementation
else else
begin begin
Message1(scan_d_handling_switch,'$'+hs); Message1(scan_d_handling_switch,'$'+hs);
t.proc{$ifdef FPCPROCVAR}(){$endif}; t.proc;
end; end;
end end
else else
@ -3228,31 +3224,31 @@ exit_label:
mac_scannerdirectives:=TDictionary.Create; mac_scannerdirectives:=TDictionary.Create;
{ Default directives and conditionals for all modes } { Default directives and conditionals for all modes }
AddDirective('I',directive_all, {$ifdef FPCPROCVAR}@{$endif}dir_include); AddDirective('I',directive_all, @dir_include);
{ Common directives and conditionals } { Common directives and conditionals }
AddDirective('DEFINE',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_define); AddDirective('DEFINE',directive_turbo, @dir_define);
AddDirective('UNDEF',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_undef); AddDirective('UNDEF',directive_turbo, @dir_undef);
AddDirective('INCLUDE',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_include); AddDirective('INCLUDE',directive_turbo, @dir_include);
AddDirective('LIBPREFIX',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_libprefix); AddDirective('LIBPREFIX',directive_turbo, @dir_libprefix);
AddDirective('LIBSUFFIX',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_libsuffix); AddDirective('LIBSUFFIX',directive_turbo, @dir_libsuffix);
AddDirective('EXTENSION',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_extension); AddDirective('EXTENSION',directive_turbo, @dir_extension);
AddConditional('ELSE',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_else); AddConditional('ELSE',directive_turbo, @dir_else);
AddConditional('ELSEIF',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_elseif); AddConditional('ELSEIF',directive_turbo, @dir_elseif);
AddConditional('ENDIF',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_endif); AddConditional('ENDIF',directive_turbo, @dir_endif);
AddConditional('IFEND',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_endif); AddConditional('IFEND',directive_turbo, @dir_endif);
AddConditional('IF',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_if); AddConditional('IF',directive_turbo, @dir_if);
AddConditional('IFDEF',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_ifdef); AddConditional('IFDEF',directive_turbo, @dir_ifdef);
AddConditional('IFNDEF',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_ifndef); AddConditional('IFNDEF',directive_turbo, @dir_ifndef);
AddConditional('IFOPT',directive_turbo, {$ifdef FPCPROCVAR}@{$endif}dir_ifopt); AddConditional('IFOPT',directive_turbo, @dir_ifopt);
{ Default Mac directives and conditionals: } { Default Mac directives and conditionals: }
AddDirective('SETC',directive_mac, {$ifdef FPCPROCVAR}@{$endif}dir_setc); AddDirective('SETC',directive_mac, @dir_setc);
AddDirective('DEFINEC',directive_mac, {$ifdef FPCPROCVAR}@{$endif}dir_define); AddDirective('DEFINEC',directive_mac, @dir_define);
AddConditional('IFC',directive_mac, {$ifdef FPCPROCVAR}@{$endif}dir_if); AddConditional('IFC',directive_mac, @dir_if);
AddConditional('ELSEC',directive_mac, {$ifdef FPCPROCVAR}@{$endif}dir_else); AddConditional('ELSEC',directive_mac, @dir_else);
AddConditional('ENDC',directive_mac, {$ifdef FPCPROCVAR}@{$endif}dir_endif); AddConditional('ENDC',directive_mac, @dir_endif);
end; end;
@ -3267,7 +3263,11 @@ exit_label:
end. end.
{ {
$Log$ $Log$
Revision 1.91 2004-10-09 11:29:15 olle Revision 1.92 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.91 2004/10/09 11:29:15 olle
* Exchanged hardcoded "./" to CurDirRelPath * Exchanged hardcoded "./" to CurDirRelPath
Revision 1.90 2004/09/29 06:52:43 mazen Revision 1.90 2004/09/29 06:52:43 mazen

View File

@ -222,7 +222,7 @@ implementation
writeln('Symtable ',name^) writeln('Symtable ',name^)
else else
writeln('Symtable <not named>'); writeln('Symtable <not named>');
symsearch.foreach({$ifdef FPCPROCVAR}@{$endif}dumpsym,nil); symsearch.foreach(@dumpsym,nil);
end; end;
{$endif EXTDEBUG} {$endif EXTDEBUG}
@ -331,7 +331,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.22 2004-07-09 22:17:32 peter Revision 1.23 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.22 2004/07/09 22:17:32 peter
* revert has_localst patch * revert has_localst patch
* replace aktstaticsymtable/aktglobalsymtable with current_module * replace aktstaticsymtable/aktglobalsymtable with current_module

View File

@ -40,9 +40,6 @@ interface
aasmbase,aasmtai, aasmbase,aasmtai,
cpubase,cpuinfo, cpubase,cpuinfo,
cgbase,parabase cgbase,parabase
{$ifdef Delphi}
,dmisc
{$endif}
; ;
@ -829,11 +826,7 @@ interface
implementation implementation
uses uses
{$ifdef Delphi}
sysutils,
{$else Delphi}
strings, strings,
{$endif Delphi}
{ global } { global }
verbose, verbose,
{ target } { target }
@ -3236,7 +3229,7 @@ implementation
strpcopy(state.stabstring,'s'+tostr(size)); strpcopy(state.stabstring,'s'+tostr(size));
state.recoffset:=0; state.recoffset:=0;
state.stabsize:=strlen(state.stabstring); state.stabsize:=strlen(state.stabstring);
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}field_addname,@state); symtable.foreach(@field_addname,@state);
state.stabstring[state.stabsize]:=';'; state.stabstring[state.stabsize]:=';';
state.stabstring[state.stabsize+1]:=#0; state.stabstring[state.stabsize+1]:=#0;
reallocmem(state.stabstring,state.stabsize+2); reallocmem(state.stabstring,state.stabsize+2);
@ -3248,7 +3241,7 @@ implementation
begin begin
if (stab_state in [stab_state_writing,stab_state_written]) then if (stab_state in [stab_state_writing,stab_state_written]) then
exit; exit;
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}field_concatstabto,asmlist); symtable.foreach(@field_concatstabto,asmlist);
inherited concatstabto(asmlist); inherited concatstabto(asmlist);
end; end;
{$endif GDB} {$endif GDB}
@ -3257,7 +3250,7 @@ implementation
procedure trecorddef.write_child_rtti_data(rt:trttitype); procedure trecorddef.write_child_rtti_data(rt:trttitype);
begin begin
FRTTIType:=rt; FRTTIType:=rt;
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}generate_field_rtti,nil); symtable.foreach(@generate_field_rtti,nil);
end; end;
@ -3271,9 +3264,9 @@ implementation
rttiList.concat(Tai_const.Create_32bit(size)); rttiList.concat(Tai_const.Create_32bit(size));
Count:=0; Count:=0;
FRTTIType:=rt; FRTTIType:=rt;
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}count_field_rtti,nil); symtable.foreach(@count_field_rtti,nil);
rttiList.concat(Tai_const.Create_32bit(Count)); rttiList.concat(Tai_const.Create_32bit(Count));
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}write_field_rtti,nil); symtable.foreach(@write_field_rtti,nil);
end; end;
@ -5070,7 +5063,7 @@ implementation
sd:=nil; sd:=nil;
while assigned(o) do while assigned(o) do
begin begin
o.symtable.foreach_static({$ifdef FPCPROCVAR}@{$endif}_searchdestructor,@sd); o.symtable.foreach_static(@_searchdestructor,@sd);
if assigned(sd) then if assigned(sd) then
begin begin
searchdestructor:=sd; searchdestructor:=sd;
@ -5254,7 +5247,7 @@ implementation
{virtual table to implement yet} {virtual table to implement yet}
state.recoffset:=0; state.recoffset:=0;
state.stabsize:=strlen(state.stabstring); state.stabsize:=strlen(state.stabstring);
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}field_addname,@state); symtable.foreach(@field_addname,@state);
if (oo_has_vmt in objectoptions) then if (oo_has_vmt in objectoptions) then
if not assigned(childof) or not(oo_has_vmt in childof.objectoptions) then if not assigned(childof) or not(oo_has_vmt in childof.objectoptions) then
begin begin
@ -5262,7 +5255,7 @@ implementation
strpcopy(state.stabstring+state.stabsize,ts); strpcopy(state.stabstring+state.stabsize,ts);
inc(state.stabsize,length(ts)); inc(state.stabsize,length(ts));
end; end;
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}proc_addname,@state); symtable.foreach(@proc_addname,@state);
if (oo_has_vmt in objectoptions) then if (oo_has_vmt in objectoptions) then
begin begin
anc := self; anc := self;
@ -5355,8 +5348,8 @@ implementation
anc:=anc.childof; anc:=anc.childof;
anc.concatstabto(asmlist); anc.concatstabto(asmlist);
end; end;
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}field_concatstabto,asmlist); symtable.foreach(@field_concatstabto,asmlist);
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}proc_concatstabto,asmlist); symtable.foreach(@proc_concatstabto,asmlist);
stab_state:=stab_state_used; stab_state:=stab_state_used;
if objecttype=odt_class then if objecttype=odt_class then
begin begin
@ -5560,9 +5553,9 @@ implementation
FRTTIType:=rt; FRTTIType:=rt;
case rt of case rt of
initrtti : initrtti :
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}generate_field_rtti,nil); symtable.foreach(@generate_field_rtti,nil);
fullrtti : fullrtti :
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}generate_published_child_rtti,nil); symtable.foreach(@generate_published_child_rtti,nil);
else else
internalerror(200108301); internalerror(200108301);
end; end;
@ -5685,7 +5678,7 @@ implementation
else else
i:=0; i:=0;
count:=0; count:=0;
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}count_published_properties,nil); symtable.foreach(@count_published_properties,nil);
next_free_name_index:=i+count; next_free_name_index:=i+count;
end; end;
@ -5719,9 +5712,9 @@ implementation
begin begin
count:=0; count:=0;
FRTTIType:=rt; FRTTIType:=rt;
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}count_field_rtti,nil); symtable.foreach(@count_field_rtti,nil);
rttiList.concat(Tai_const.Create_32bit(count)); rttiList.concat(Tai_const.Create_32bit(count));
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}write_field_rtti,nil); symtable.foreach(@write_field_rtti,nil);
end; end;
end; end;
fullrtti : fullrtti :
@ -5745,7 +5738,7 @@ implementation
count:=0; count:=0;
{ write it } { write it }
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}count_published_properties,nil); symtable.foreach(@count_published_properties,nil);
rttiList.concat(Tai_const.Create_16bit(count)); rttiList.concat(Tai_const.Create_16bit(count));
{ write unit name } { write unit name }
@ -5758,7 +5751,7 @@ implementation
{ write published properties count } { write published properties count }
count:=0; count:=0;
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}count_published_properties,nil); symtable.foreach(@count_published_properties,nil);
rttiList.concat(Tai_const.Create_16bit(count)); rttiList.concat(Tai_const.Create_16bit(count));
{$ifdef cpurequiresproperalignment} {$ifdef cpurequiresproperalignment}
@ -5774,7 +5767,7 @@ implementation
else else
count:=0; count:=0;
symtable.foreach({$ifdef FPCPROCVAR}@{$endif}write_property_info,nil); symtable.foreach(@write_property_info,nil);
end; end;
end; end;
end; end;
@ -6204,7 +6197,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.258 2004-10-10 21:08:55 peter Revision 1.259 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.258 2004/10/10 21:08:55 peter
* parameter regvar fixes * parameter regvar fixes
Revision 1.257 2004/10/04 21:23:15 florian Revision 1.257 2004/10/04 21:23:15 florian

View File

@ -305,11 +305,7 @@ interface
implementation implementation
uses uses
{$ifdef Delphi}
sysutils,
{$else Delphi}
strings, strings,
{$endif Delphi}
{ global } { global }
verbose, verbose,
{ target } { target }
@ -2255,7 +2251,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.187 2004-10-13 18:47:45 peter Revision 1.188 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.187 2004/10/13 18:47:45 peter
* fix misplaced begin..end for self stabs * fix misplaced begin..end for self stabs
* no fpu regable for staticsymtable * no fpu regable for staticsymtable

View File

@ -776,7 +776,7 @@ implementation
if (tsym(p).typ=typesym) and if (tsym(p).typ=typesym) and
(ttypesym(p).restype.def.deftype=objectdef) and (ttypesym(p).restype.def.deftype=objectdef) and
(ttypesym(p).restype.def.typesym=tsym(p)) then (ttypesym(p).restype.def.typesym=tsym(p)) then
tobjectdef(ttypesym(p).restype.def).symtable.foreach({$ifdef FPCPROCVAR}@{$endif}TestPrivate,nil); tobjectdef(ttypesym(p).restype.def).symtable.foreach(@TestPrivate,nil);
end; end;
@ -815,31 +815,31 @@ implementation
{ checks, if all procsyms and methods are defined } { checks, if all procsyms and methods are defined }
procedure tstoredsymtable.check_forwards; procedure tstoredsymtable.check_forwards;
begin begin
foreach({$ifdef FPCPROCVAR}@{$endif}check_forward,nil); foreach(@check_forward,nil);
end; end;
procedure tstoredsymtable.checklabels; procedure tstoredsymtable.checklabels;
begin begin
foreach({$ifdef FPCPROCVAR}@{$endif}labeldefined,nil); foreach(@labeldefined,nil);
end; end;
procedure tstoredsymtable.allsymbolsused; procedure tstoredsymtable.allsymbolsused;
begin begin
foreach({$ifdef FPCPROCVAR}@{$endif}varsymbolused,nil); foreach(@varsymbolused,nil);
end; end;
procedure tstoredsymtable.allprivatesused; procedure tstoredsymtable.allprivatesused;
begin begin
foreach({$ifdef FPCPROCVAR}@{$endif}objectprivatesymbolused,nil); foreach(@objectprivatesymbolused,nil);
end; end;
procedure tstoredsymtable.unchain_overloaded; procedure tstoredsymtable.unchain_overloaded;
begin begin
foreach({$ifdef FPCPROCVAR}@{$endif}unchain_overloads,nil); foreach(@unchain_overloads,nil);
end; end;
@ -894,7 +894,7 @@ implementation
function tstoredsymtable.needs_init_final : boolean; function tstoredsymtable.needs_init_final : boolean;
begin begin
b_needs_init_final:=false; b_needs_init_final:=false;
foreach({$ifdef FPCPROCVAR}@{$endif}_needs_init_final,nil); foreach(@_needs_init_final,nil);
needs_init_final:=b_needs_init_final; needs_init_final:=b_needs_init_final;
end; end;
@ -2186,7 +2186,7 @@ implementation
_defaultprop:=nil; _defaultprop:=nil;
while assigned(pd) do while assigned(pd) do
begin begin
pd.symtable.foreach({$ifdef FPCPROCVAR}@{$endif}tstoredsymtable(pd.symtable).testfordefaultproperty,@_defaultprop); pd.symtable.foreach(@tstoredsymtable(pd.symtable).testfordefaultproperty,@_defaultprop);
if assigned(_defaultprop) then if assigned(_defaultprop) then
break; break;
pd:=pd.childof; pd:=pd.childof;
@ -2314,7 +2314,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.158 2004-10-12 19:51:13 peter Revision 1.159 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.158 2004/10/12 19:51:13 peter
* all checking for visibility is now done by is_visible_for_object * all checking for visibility is now done by is_visible_for_object
Revision 1.157 2004/10/11 15:48:15 peter Revision 1.157 2004/10/11 15:48:15 peter

View File

@ -52,8 +52,8 @@ type
pjmp_buf = ^jmp_buf; pjmp_buf = ^jmp_buf;
function setjmp(var rec : jmp_buf) : longint;{$ifdef Delphi}stdcall;{$else}{$ifndef ver1_0}oldfpccall;{$endif}{$endif} function setjmp(var rec : jmp_buf) : longint;{$ifndef ver1_0}oldfpccall;{$endif}
procedure longjmp(const rec : jmp_buf;return_value : longint);{$ifdef Delphi}stdcall;{$else}{$ifndef ver1_0}oldfpccall;{$endif}{$endif} procedure longjmp(const rec : jmp_buf;return_value : longint);{$ifndef ver1_0}oldfpccall;{$endif}
{$endif HASNOLONGJMP} {$endif HASNOLONGJMP}
@ -258,7 +258,11 @@ implementation
end. end.
{ {
$Log$ $Log$
Revision 1.11 2004-06-20 08:55:30 florian Revision 1.12 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.11 2004/06/20 08:55:30 florian
* logs truncated * logs truncated
Revision 1.10 2004/02/12 16:00:39 peter Revision 1.10 2004/02/12 16:00:39 peter

View File

@ -24,11 +24,6 @@ unit verbose;
{$i fpcdefs.inc} {$i fpcdefs.inc}
{ Don't include messages in the executable }
{$ifdef Delphi}
{$define EXTERN_MSG}
{$endif}
interface interface
uses uses
@ -383,7 +378,7 @@ var
procedure ShowStatus; procedure ShowStatus;
begin begin
UpdateStatus; UpdateStatus;
if do_status{$ifdef FPCPROCVAR}(){$endif} then if do_status() then
stop(1); stop(1);
end; end;
@ -873,7 +868,11 @@ finalization
end. end.
{ {
$Log$ $Log$
Revision 1.33 2004-09-08 11:23:31 michael Revision 1.34 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.33 2004/09/08 11:23:31 michael
+ Check if outputdir exists, Fix exitcode when displaying help pages + Check if outputdir exists, Fix exitcode when displaying help pages
Revision 1.32 2004/06/20 08:55:30 florian Revision 1.32 2004/06/20 08:55:30 florian

View File

@ -28,23 +28,13 @@ unit widestr;
uses uses
charset,globtype charset,globtype
{$ifdef delphi}
,sysutils
{$endif}
; ;
type type
tcompilerwidechar = word; tcompilerwidechar = word;
tcompilerwidecharptr = ^tcompilerwidechar; tcompilerwidecharptr = ^tcompilerwidechar;
{$ifdef delphi}
SizeInt = integer;
{ delphi doesn't allow pointer accessing as array }
tcompilerwidechararray = array[0..0] of tcompilerwidechar;
pcompilerwidechar = ^tcompilerwidechararray;
{$else}
pcompilerwidechar = ^tcompilerwidechar; pcompilerwidechar = ^tcompilerwidechar;
{$endif}
pcompilerwidestring = ^_tcompilerwidestring; pcompilerwidestring = ^_tcompilerwidestring;
_tcompilerwidestring = record _tcompilerwidestring = record
@ -152,11 +142,7 @@ unit widestr;
temp:=s2^.len; temp:=s2^.len;
if maxi>temp then if maxi>temp then
maxi:=Temp; maxi:=Temp;
{$ifdef Delphi}
temp:=SizeInt(comparemem(@s1^.data,@s2^.data,maxi));
{$else}
temp:=compareword(s1^.data^,s2^.data^,maxi); temp:=compareword(s1^.data^,s2^.data^,maxi);
{$endif}
if temp=0 then if temp=0 then
temp:=s1^.len-s2^.len; temp:=s1^.len-s2^.len;
comparewidestrings:=temp; comparewidestrings:=temp;
@ -240,7 +226,11 @@ unit widestr;
end. end.
{ {
$Log$ $Log$
Revision 1.15 2004-06-20 08:55:30 florian Revision 1.16 2004-10-15 09:14:17 mazen
- remove $IFDEF DELPHI and related code
- remove $IFDEF FPCPROCVAR and related code
Revision 1.15 2004/06/20 08:55:30 florian
* logs truncated * logs truncated
Revision 1.14 2004/06/16 20:07:10 florian Revision 1.14 2004/06/16 20:07:10 florian