Namespace cpp::
- Description
 Pike has a builtin C-style preprocessor. It works similar to the ANSI-C preprocessor but has a few extra features. These and the default set of preprocessor macros are described here.
The preprocessor is usually accessed via
MasterObject->compile_file()orMasterObject->compile_string(), but may be accessed directly by calling cpp().- See also
 
- Constant
__APPLE__
 constant__APPLE__- Description
 This define is defined when the Pike is running on MacOS X.
- Constant
__AUTO_BIGNUM__
 constant__AUTO_BIGNUM__- Description
 This define is defined when automatic bignum conversion is enabled. When enabled all integers will automatically be converted to bignums when they get bigger than what can be represented by an integer, hampering performance slightly instead of crashing the program. This define is always set since Pike 8.0.
- Constant
__BUILD__
 constant__BUILD__- Description
 This constant contains the build number of the current Pike version, represented as an integer. If another Pike version is emulated, this constant remains unaltered.
- See also
 
- Constant
__DATE__
 constant__DATE__- Description
 This define contains the current date at the time of compilation, e.g. "Jul 28 2001".
- Constant
__DIR__
 constant__DIR__- Description
 This define contains the directory path of the source file.
- Constant
__FILE__
 constant__FILE__- Description
 This define contains the file path and name of the source file.
- Constant
__HAIKU__
 constant__HAIKU__- Description
 This define is defined when the Pike is running on Haiku.
- Constant
__LINE__
 constant__LINE__- Description
 This define contains the current line number, represented as an integer, in the source file.
- Constant
__MAJOR__
 constant__MAJOR__- Description
 This define contains the major part of the current Pike version, represented as an integer. If another Pike version is emulated, this define is updated accordingly.
- See also
 
- Constant
__MINOR__
 constant__MINOR__- Description
 This define contains the minor part of the current Pike version, represented as an integer. If another Pike version is emulated, this define is updated accordingly.
- See also
 
- Constant
__NT__
 constant__NT__- Description
 This define is defined when the Pike is running on a Microsoft Windows OS, not just Microsoft Windows NT, as the name implies.
- Constant
__REAL_BUILD__
 constant__REAL_BUILD__- Description
 This define always contains the minor part of the version of the current Pike, represented as an integer.
- See also
 
- Constant
__REAL_MAJOR__
 constant__REAL_MAJOR__- Description
 This define always contains the major part of the version of the current Pike, represented as an integer.
- See also
 
- Constant
__REAL_MINOR__
 constant__REAL_MINOR__- Description
 This define always contains the minor part of the version of the current Pike, represented as an integer.
- See also
 
- Constant
__REAL_VERSION__
 constant__REAL_VERSION__- Description
 This define always contains the version of the current Pike, represented as a float.
- See also
 
- Constant
__STDC_ISO_10646__
 constant__STDC_ISO_10646__- Description
 This macro expands to the year and date (6 digits) of the Unicode standard that the Pike runtime supports.
Note that this differs slightly from the corresponding macro in the C23 standard in that it does NOT have an ending
'L'.- See also
 
- Constant
__TIME__
 constant__TIME__- Description
 This define contains the current time at the time of compilation, e.g. "12:20:51".
- Constant
__UNICODE_VERSION__
 constant__UNICODE_VERSION__- Description
 This macro expands to a decimal representation of the version of the Unicode standard that the Pike runtime supports. It is formated with the sprintf-format
%d%02d%02dwith the values major, minor and revision in order. Version 12.1 thus results in the value120100.- See also
 
- Constant
__VERSION__
 constant__VERSION__- Description
 This define contains the current Pike version as a float. If another Pike version is emulated, this define is updated accordingly.
- See also
 
- Constant
__amigaos__
 constant__amigaos__- Description
 This define is defined when the Pike is running on Amiga OS.
- Constant
static_assert
 constantstatic_assert- Description
 This define expands to the symbol _Static_assert.
It is the preferred way to perform static (ie compile-time) assertions.
- Note
 The macro can also be used to check for whether static assertions are supported.
- See also