1. A computer implemented method, comprising: processing a source code representation of a computer program in an object-oriented language into a high-level intermediate representation; and translating the high-level intermediate representation into a medium-level intermediate representation, comprising combining a name-based class name and corresponding structure-based record type into a combined class type, and using an exact class name to represent objects of that class but not those of subclasses and the combined class type as an encoding of an existential type to represent objects of the class and subclasses of the class.