mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-07 15:28:08 +02:00
21 lines
260 B
ObjectPascal
21 lines
260 B
ObjectPascal
{ test c style assignment operators }
|
|
|
|
{$COPERATORS ON}
|
|
var
|
|
i : Single;
|
|
begin
|
|
i:=1234;
|
|
i += 1;
|
|
if i<>1235 then
|
|
halt(1);
|
|
i -= 1;
|
|
if i<>1234 then
|
|
halt(2);
|
|
i *= 2;
|
|
if i<>2468 then
|
|
halt(3);
|
|
i /= 2;
|
|
if i<>1234 then
|
|
halt(4);
|
|
end.
|