Share via


Write Code That Works in the Largest Number of C Compilers

OverviewHow Do IFAQDetails

For code that is most universal among C compilers, write strictly ANSI C and ANSI C++ code.

To write strict ANSI C/C++ code

  1. Do not use the MFC library. Call Win32 APIs directly.

  2. Disable Microsoft extensions.

  3. Use the iostream library from the ANSI Standard C++ library.

  4. Use the Standard template library from the ANSI Standard C++ library.