Code select will not work in binary groovy files because the codeSelect will call the SelectionEngine that tries to parse the underlying source code as Java. We need to create a GroovyClassFile class and have it instantiated in the same way that GroovyCompilationUnit is instantiated (ie- delegated to the LanguageSupportFactory.
We also need to have both implement the same interface (maybe something like IGroovyTypeRoot). Then we need to reference the interface in all places, rather than the concrete classes.
With this in place, it would be easy to override ClassFile's call to SelectionEngine and to use our own mechanism instead.
However, this is a major refactoring and I am not comfortable doing this yet.