mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-11-21 00:59:35 +01:00
* escape $ with \$
This commit is contained in:
parent
1f990184bc
commit
5957cff999
@ -592,8 +592,13 @@ Var
|
|||||||
begin
|
begin
|
||||||
hs:='';
|
hs:='';
|
||||||
for i:=1 to length(s) do
|
for i:=1 to length(s) do
|
||||||
if (S[i]='$') and (s[i+1] in ['0'..'9']) then
|
if (S[i]='$') then
|
||||||
|
begin
|
||||||
|
if (s[i+1] in ['0'..'9']) then
|
||||||
hs:=hs+'arg'
|
hs:=hs+'arg'
|
||||||
|
else
|
||||||
|
hs:=hs+'\$';
|
||||||
|
end
|
||||||
else
|
else
|
||||||
hs:=hs+s[i];
|
hs:=hs+s[i];
|
||||||
EscapeString:=hs;
|
EscapeString:=hs;
|
||||||
@ -769,7 +774,9 @@ begin
|
|||||||
Renumberfile(Infile,OutFile);
|
Renumberfile(Infile,OutFile);
|
||||||
end;
|
end;
|
||||||
M_Tex : begin
|
M_Tex : begin
|
||||||
WriteTexFile(InFile,OutFile+'.tex');
|
if pos('.tex',outfile)=0 then
|
||||||
|
Outfile:=OutFile+'.tex';
|
||||||
|
WriteTexFile(InFile,Outfile);
|
||||||
end;
|
end;
|
||||||
M_Intel : begin
|
M_Intel : begin
|
||||||
Loadmsgfile(InFile);
|
Loadmsgfile(InFile);
|
||||||
@ -790,7 +797,10 @@ begin
|
|||||||
end.
|
end.
|
||||||
{
|
{
|
||||||
$Log$
|
$Log$
|
||||||
Revision 1.11 2000-07-09 17:01:26 peter
|
Revision 1.12 2000-07-09 17:39:05 peter
|
||||||
|
* escape $ with \$
|
||||||
|
|
||||||
|
Revision 1.11 2000/07/09 17:01:26 peter
|
||||||
* replace only $ with arg if next char is a number
|
* replace only $ with arg if next char is a number
|
||||||
|
|
||||||
Revision 1.10 2000/07/09 16:30:59 peter
|
Revision 1.10 2000/07/09 16:30:59 peter
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user