Remove string dups in grammar, add stringDup for all ref'd vars
Restrict duping to strings actually inside image memory bounds