FUNCTIONS CORE

Compiler()

Return the C compiler that built the xDev runtime

Syntax

Signature
Compiler( ) --> cCompilerVersion

Arguments

None.

Return value

The name and the version of the C compiler, for example "Clang 22.1.0".

Description

Compiler() gives the same text as Version( VERSION_COMPILER ).

Example

Compiler.prg
#include "version.ch"

PROCEDURE Main()

   Check( 'Compiler() is Version()          ', Compiler(), Version( VERSION_COMPILER ) )
   Check( 'Compiler() is not empty          ', Empty( Compiler() ), .F. )

   QOut( "" )
   QOut( Compiler() )

RETURN

STATIC PROCEDURE Check( cTitle, xResult, xExpected )

   QOut( cTitle + IIF( xResult == xExpected, "OK", "ERROR" ) )

RETURN

Output

Compiler() is Version()          OK
Compiler() is not empty          OK

See also