[fpc-devel] How to convert set to integer and vice versa
Gennady Agranov
gennadyagranov at gmail.com
Tue Jul 22 03:37:19 CEST 2014
Hi,
I am new to FPC, but I do like it - thanks!
We are trying to switch from Delphi to FPC, but I am stuck with the
following issue - in Delphi you can cast "set" to "integer" and get it
back later - again by casting. In our case it is used for persistence
purposes.
We have a lot of different set types - i really do not want to write
set<->integer converter for every set type we have :(
Actually I did find a way - I use ^ and @ and cast pointers,
but is there a way to write general set<->integer converter in FPC that
I do not have to worry whether it will work or not?
And what actually -CPPACKSET=0 does - documentation is not clear - at
least for me :)
Thanks,
Gennady
More information about the fpc-devel
mailing list