|
Only define a type in one place, even if it is used in more than one module. If you need a type definition in more than one module, put the type definition in a header file that several modules can include. |
There are places where we use typedefs to give names to types.
For example, you will write
typedef int* ER;which says that ER is a name for type int*. Anyplace where something should have type ER, write ER, not int*. Use the logical type name in preference to the physical type name. But do not use ER for int* in places where logical name ER is not appropriate. |