A header file with the appropriate 'static inline' functions would serve this purpose nicely; it doesn't need to be compiled and distributed as a library, but the function calls are type-checked and can be written more easily than preprocessor macros.