Fabio,
>as Gregory has said, I have not never made reference the algorithm of David.
>
>Moreover, the algorithm of David is not the best possible one in the case of CHRTRAN().
>When the LEN(param2)=LEN(param3) never copy it is necessary ( a single pointer is sufficient ).
>And CHRTRAN is similar to a ASCAN/LOOKUP/SELECT JOIN, and therefore in some cases
You started this thread based on the premise where characters are being removed from the output result.
CHRTRAN() is already fast enough under the LEN(param2)=LEN(param3) condition, so no other alternate code is required. VFP has
O(n) performance when doing character for character substitution.
I never said my code was a chrtran() replacement, I only offered it as an illustration of how it could be done better.