There are two main approaches used to represent foreign objects: an integer that represents an address in memory, and a object that also includes run-time typing. The advantage of run-time typing is the system can dereference pointers and perform array access without those functions requiring a type at the cost of additional overhead to generate and store the run-time typing. The advantage of integer representation, at least for AllegroCL, is that the compiler can generate inline code to dereference pointers. Further, the overhead of the run-time type information is eliminated. The disadvantage is the program must then supply the type to the functions to dereference objects and array.