mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-12-16 03:10:42 +01:00
to the parser, so that it only looks at what the programmer wrote rather
than at all statements that the compiler may generate internally
(mantis #11619)
+ several tests for {$x-} mode
* modified tenumerators1 so it compiles without extended syntax enabled
(to check for..in with {$x-})
git-svn-id: trunk@15075 -
27 lines
328 B
ObjectPascal
27 lines
328 B
ObjectPascal
{ %norun }
|
|
{$mode objfpc}
|
|
{$inline on}
|
|
{$x-}
|
|
|
|
function Min(a, b: Double): Double;inline;
|
|
begin
|
|
if a < b then
|
|
Result := a
|
|
else
|
|
Result := b;
|
|
end;
|
|
|
|
function Max(a, b: Double): Double;inline;
|
|
begin
|
|
if a > b then
|
|
Result := a
|
|
else
|
|
Result := b;
|
|
end;
|
|
|
|
var
|
|
a, b: double;
|
|
begin
|
|
a:=min(max(a,b),min(a,b));
|
|
end.
|