On 11/02/2011 09:41, José Mejuto wrote: > If no checks about utf8 integrity are performed they should not be > that "lot slower", only a bit slower, at least utf8pos, utf8copy is > for sure slower. > A different thing is that current implementation is a bit overengined > which add some overhead. > > Is it logical/safe that utf8 functions do not check utf8 integrity ? > I'm talking about utf8pos, utf8copy, etc... >
Maybe make the sanity check optional with default true ? Or some unit flag, default true and the utf* routines could force check if told so ? Not that I know anything about this code but why not let people who know what they are doing to skip the check or call check when they know they need to? (and as I said, in order not to break existing code, default would be to check always) My £0.000002. Lukasz -- _______________________________________________ Lazarus mailing list [email protected] http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus
