mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-06-06 12:18:28 +02:00
* only check for _PROPERTY as a regular token, so that
{$modeswitch properties-} also affects global properties (mantis #25861) git-svn-id: trunk@27758 -
This commit is contained in:
parent
dc17b7ef46
commit
362ff5ad01
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -12734,6 +12734,7 @@ tests/webtbf/tw2562.pp svneol=native#text/plain
|
||||
tests/webtbf/tw25622.pp svneol=native#text/plain
|
||||
tests/webtbf/tw25622a.pp svneol=native#text/plain
|
||||
tests/webtbf/tw25788.pp svneol=native#text/pascal
|
||||
tests/webtbf/tw25861.pp svneol=native#text/plain
|
||||
tests/webtbf/tw25862.pp svneol=native#text/plain
|
||||
tests/webtbf/tw25915.pp svneol=native#text/pascal
|
||||
tests/webtbf/tw25951.pp svneol=native#text/pascal
|
||||
|
@ -2210,7 +2210,14 @@ implementation
|
||||
Message(parser_w_unsupported_feature);
|
||||
consume(_BEGIN);
|
||||
end;
|
||||
end
|
||||
end;
|
||||
_PROPERTY:
|
||||
begin
|
||||
if (m_fpc in current_settings.modeswitches) then
|
||||
property_dec
|
||||
else
|
||||
break;
|
||||
end;
|
||||
else
|
||||
begin
|
||||
case idtoken of
|
||||
@ -2233,13 +2240,6 @@ implementation
|
||||
else
|
||||
break;
|
||||
end;
|
||||
_PROPERTY:
|
||||
begin
|
||||
if (m_fpc in current_settings.modeswitches) then
|
||||
property_dec
|
||||
else
|
||||
break;
|
||||
end;
|
||||
else
|
||||
break;
|
||||
end;
|
||||
|
8
tests/webtbf/tw25861.pp
Normal file
8
tests/webtbf/tw25861.pp
Normal file
@ -0,0 +1,8 @@
|
||||
{ %fail }
|
||||
|
||||
{$MODE OBJFPC} {$MODESWITCH PROPERTIES-}
|
||||
program test;
|
||||
function GetBar(): Cardinal; begin Result := 0; end;
|
||||
property Bar: Cardinal read GetBar;
|
||||
begin Writeln(Bar); end.
|
||||
|
Loading…
Reference in New Issue
Block a user