I don't understand what changes should be made
The variables that are global ( not localised to the function ) should be localised so that their value does not carry over for the next iteration of the routine.
(defun c:numtext
( / c_doc ms s_no e_no str CNT C_DOC PFIX PS SFIX SV_LST SV_VALS S_FIX X Y
) ;;; similar to this
;;; >>>>
)
added:
I knew they were global because I checked the code in VLIDE.
Tools » Environment Options » General Options ->> Diagnostic ->> set 'Toggle Statistics ... ON
Then
Tools » Check Text in Editor
or
Tools » Check Selection