[fpc-devel] Forin feature with tBits
Alexander Klenin
klenin at gmail.com
Sat Nov 7 12:12:16 CET 2009
On Sat, Nov 7, 2009 at 20:32, Dariusz Mazur <darekm at emadar.com> wrote:
> Alexander Klenin pisze:
>> Obviously, the implementation should not call FindFirstBit,
>> but copy it's logic. To avoid code duplication,
>> I think you can to it the other way around -- let FindFirstBit
>> create a enumerator and store it inside the TBits instance.
>>
>
> I'm not sure, but if this solution is not multithread aware too?
Yes, as I wrote below, the best solution would be to drop the current
interface...
>> It would be even better to drop FindFirstBit/FindNextBit altogether,
>> but I do not know how large compatibility problem it might cause.
... but _if_ the backwards compatibility is deemed important enough,
my suggestion will allow to maintain it with the minimal code duplication.
--
Alexander S. Klenin
More information about the fpc-devel
mailing list