mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-20 19:29:26 +02:00
* interpret -daaa:=bbb after -Sm was passed as a macro definition, resolves #27529
git-svn-id: trunk@30271 -
This commit is contained in:
parent
36e79a874e
commit
3396e2e1f4
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -14330,6 +14330,7 @@ tests/webtbs/tw2738.pp svneol=native#text/plain
|
||||
tests/webtbs/tw2739.pp svneol=native#text/plain
|
||||
tests/webtbs/tw27424.pp svneol=native#text/pascal
|
||||
tests/webtbs/tw27515.pp svneol=native#text/pascal
|
||||
tests/webtbs/tw27529.pp svneol=native#text/pascal
|
||||
tests/webtbs/tw2758.pp svneol=native#text/plain
|
||||
tests/webtbs/tw2763.pp svneol=native#text/plain
|
||||
tests/webtbs/tw27634.pp svneol=native#text/plain
|
||||
|
@ -1349,7 +1349,12 @@ begin
|
||||
StopOptions(1);
|
||||
end;
|
||||
if l>0 then
|
||||
set_system_compvar(hs,Copy(more,l+2,255))
|
||||
begin
|
||||
if cs_support_macro in init_settings.moduleswitches then
|
||||
set_system_macro(hs,Copy(more,l+2,255))
|
||||
else
|
||||
set_system_compvar(hs,Copy(more,l+2,255));
|
||||
end
|
||||
else
|
||||
def_system_macro(hs);
|
||||
end;
|
||||
|
17
tests/webtbs/tw27529.pp
Normal file
17
tests/webtbs/tw27529.pp
Normal file
@ -0,0 +1,17 @@
|
||||
{ %OPT=-Sm -dMY_VAR:=123 }
|
||||
program test;
|
||||
|
||||
{$IF DEFINED(MY_VAR)}
|
||||
{$INFO MY_VAR defined}
|
||||
{$IF MY_VAR=123}
|
||||
{$INFO MY_VAR = 123}
|
||||
{$ELSE}
|
||||
{$INFO MY_VAR <> 123}
|
||||
{$ENDIF}
|
||||
{$ENDIF}
|
||||
|
||||
begin
|
||||
writeln(MY_VAR);
|
||||
if MY_VAR<>123 then
|
||||
halt(1);
|
||||
end.
|
Loading…
Reference in New Issue
Block a user