On 12 Oct 2011, at 10:13, Jonas Maebe wrote:
That would indeed require some ifdefs to keep the code compilable
also by Delphi. No solution will be completely free.
Well, an alternative could be to add a global directive such as
{$modeswitch duplicate_all_string_based_code}
whereby anything in that unit is first parsed as if the "string" types
were a generic type parameter, and the then compiler automatically
generates specializations for unicodestring and ansistring variants
for all declarations/implementations involving at least one string-
type entity.
Jonas
_______________________________________________
fpc-devel maillist - fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel