Single Sourcing with Polymorphic Types

Autodesk and Microsoft both define polymorphic types to allow multiple targets to be built from a single source stream. See "Polymorphic Types".

To build both 32-bit and 64-bit targets from a single code stream, you should check your code for variables and parameters that represent pointers and redefine their types with appropriate polymorphic types. Do not simply replace every instance of a 32-bit variable with a 64-bit polymorphic type, as you may run into compatibility problems with some of AutoCAD’s APIs. You may work around this by using temporary variables, wrapper functions, or other such techniques.

If your application defines its own types that are sensitive to 64-bit porting issues, you should consider replacing those types with polymorphic types that you define.