Made Language.addFileExtension public

Fixes #2966