* removed memavail

This commit is contained in:
peter 2004-11-22 17:52:19 +00:00
parent 295d18939a
commit 46d1fc9546
5 changed files with 75 additions and 132 deletions

View File

@ -44,15 +44,6 @@ interface
uses LexBase;
{$IFNDEF Win32}
var max_bytes : LongInt;
(* available memory *)
function n_bytes : LongInt;
(* memory actually used *)
{$ENDIF}
const
(* Maximum table sizes: *)
@ -206,13 +197,6 @@ implementation
uses LexMsgs;
{$IFNDEF Win32}
function n_bytes : LongInt;
begin
n_bytes := max_bytes-memAvail
end(*n_bytes*);
{$ENDIF}
(* Hash table routines: *)
function lookup(k : Integer) : String;
@ -466,10 +450,6 @@ begin
verbose := false;
optimize := false;
{$IFNDEF Win32}
max_bytes := memAvail;
{$ENDIF}
n_pos := 0;
n_states := 0;
n_trans := 0;

View File

@ -732,12 +732,6 @@ begin
if warnings>0 then writeln(warnings, ' warnings.');
{$ifndef fpc}
{$IFNDEF Win32}
writeln( n_bytes, '/', max_bytes, ' bytes of memory used.');
{$ENDIF}
{$endif}
(* terminate: *)
if errors>0 then erase(yyout);

View File

@ -2145,10 +2145,10 @@ function yylex : integer;
('0'<=line[cno]) and (line[cno]<='9') or
(line[cno]='_') or
(line[cno]='.') ) do
begin
idstr := idstr+line[cno];
inc(cno)
end;
begin
idstr := idstr+line[cno];
inc(cno)
end;
yylval := get_key(idstr);
scan;
if not end_of_input and (line[cno]=':') then
@ -2366,9 +2366,9 @@ function yylex : integer;
else
case line[cno] of
'A'..'Z', 'a'..'z', '_' : yylex := scan_ident;
'''', '"' : yylex := scan_literal;
'0'..'9' : yylex := scan_num;
'%', '\' : yylex := scan_keyword;
'''', '"' : yylex := scan_literal;
'0'..'9' : yylex := scan_num;
'%', '\' : yylex := scan_keyword;
'=' :
if (cno<length(line)) and (line[succ(cno)]='{') then
begin
@ -2377,7 +2377,7 @@ function yylex : integer;
end
else
yylex := scan_char;
else yylex := scan_char;
else yylex := scan_char;
end;
if lno=lno0 then
tokleng := cno-cno0
@ -2512,12 +2512,6 @@ begin
if warnings>0 then writeln(warnings, ' warnings.');
{$ifndef fpc}
{$IFNDEF Win32}
writeln( n_bytes, '/', max_bytes, ' bytes of memory used.');
{$ENDIF}
{$endif}
(* terminate: *)
if errors>0 then

View File

@ -848,12 +848,6 @@ begin
if warnings>0 then writeln(warnings, ' warnings.');
{$ifndef fpc}
{$IFNDEF Win32}
writeln( n_bytes, '/', max_bytes, ' bytes of memory used.');
{$ENDIF}
{$endif}
(* terminate: *)
if errors>0 then

View File

@ -48,14 +48,6 @@ uses
YaccBase;
{$IFNDEF Win32}
var max_bytes : LongInt;
(* available memory *)
function n_bytes : LongInt;
(* memory actually used *)
{$ENDIF}
const
(* Maximum table sizes: *)
@ -431,13 +423,6 @@ implementation
uses YaccMsgs;
{$IFNDEF Win32}
function n_bytes : LongInt;
begin
n_bytes := max_bytes-memAvail
end(*n_bytes*);
{$ENDIF}
(* Symbol table routines: *)
function new_nt : Integer;
@ -929,10 +914,6 @@ begin
debug := false;
startnt := 0;
{$IFNDEF Win32}
max_bytes := memAvail;
{$ENDIF}
n_nts := 1;
n_lits := 257;
n_rules := 0;