<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8">
</head>
<body text="#000000" bgcolor="#FFFFFF">
<font face="monospace">Consider the following program:<br>
<br>
program Project1;<br>
<br>
type<br>
TMyEnum = (<br>
a = 1,<br>
b = 3,<br>
c = 5<br>
);<br>
TMySet = set of TMyEnum;<br>
var<br>
Item: TMyEnum;<br>
<br>
begin<br>
for Item in TMySet do<br>
Writeln('Value = ', Integer(Item));<br>
end.<br>
<br>
<br>
I would expect the output of the program to contain the values 1,
3 and 5 only. But the actual output is:<br>
Value = 1
<br>
Value = 2
<br>
Value = 3
<br>
Value = 4
<br>
Value = 5
<br>
<br>
Is this a bug or a know limitation of the "for ... In ... do"
loop?<br>
<br>
I am using fpc 2.6.4<br>
<br>
Regards,<br>
Torsten.<br>
<br>
</font>
</body>
</html>