Lester Caine wrote on 03/03/2016 13:18:
Actually my problem is even more simple than that - although it may be
possible to further filter the lookup for 'var ' ( note the space ) many
of the results are simply not text that needs changing.

The script that Colin linked (https://gist.github.com/colinodell/5fb5e5d474674f294a38) uses an in-language tokenizer, not just text find-and-replace, so this is a solved problem. If this turns out to not be smart enough, one built on top of Nikita's PHP-Parser project would be pretty easy as well: https://github.com/nikic/PHP-Parser/

Regards,
--
Rowan Collins
[IMSoP]

--
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to