Qualify references to ATN class in generated code if it would alias a token

Fixes #561