Skip to content

Specific definitions by some C/C++ compilers

Notifications You must be signed in to change notification settings

gdsotirov/specific_defs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

14 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Specific definitions

Definitions automatically provided by the preprocessors of some compilers.

Usage

Build the program by running make and then run it to see what is defined.

The easier way

Compilers have they way for reporting predefined macros. For GCC it could be done like this (see Options Controlling the Preprocessor):

  • For GCC (C language): gcc -dM -E - < /dev/null
  • For G++ (C++ language): g++ -dM -E -x c++ - < /dev/null

Note: Option -x is important for g++, so that input is considered C++ source and you see all the pre-defined macros.

Resources

About

Specific definitions by some C/C++ compilers

Topics

Resources

Stars

Watchers

Forks