JEDI Help:CompilerSettings

From Project JEDI Wiki
Jump to navigationJump to search
JEDI Help

Search in JEDI Help

 
Search in all projects
 


Summary

Compiler symbol for detecting compiler settings


Pascal

 {$IFDEF SYMBOL}
 // The piece of code will be compiled only if this compiler setting is enabled
 {$ENDIF SYMBOL}
 // These symbols can also be used for restoring the initial compiler settings after explicit changes in the code:
 {$Q-}
 // this code will be compiled with disabled numeric overflows
 {$IFDEF OVERFLOWCHECKS_ON}
 {$Q+}
 {$ENDIF OVERFLOWCHECKS_ON}
 // the following code will be compiled with previous compiler settings


Description

Once jedi.inc is included at the top of your pascal source file, the following compiler symbols are defined depending on your compiler settings.
These symbols can be used for testing or restoring the initial compiler settings.

Symbol Description
ALIGN_ON Compiling in the A+ state (no alignment)
BOOLEVAL_ON Compiling in the B+ state (complete boolean evaluation)
ASSERTIONS_ON Compiling in the C+ state (assertions on)
DEBUGINFO_ON Compiling in the D+ state (debug info generation on)
IMPORTEDDATA_ON Compiling in the G+ state (creation of imported data references)
LONGSTRINGS_ON Compiling in the H+ state (string defined as AnsiString)
IOCHECKS_ON Compiling in the I+ state (I/O checking enabled)
WRITEABLECONST_ON Compiling in the J+ state (typed constants can be modified)
LOCALSYMBOLS Compiling in the L+ state (local symbol generation)
LOCALSYMBOLS_ON Alias of LOCALSYMBOLS
TYPEINFO_ON Compiling in the M+ state (RTTI generation on)
OPTIMIZATION_ON Compiling in the O+ state (code optimization on)
OPENSTRINGS_ON Compiling in the P+ state (variable string parameters are openstrings)
OVERFLOWCHECKS_ON Compiling in the Q+ state (overflow checing on)
RANGECHECKS_ON Compiling in the R+ state (range checking on)
TYPEDADDRESS_ON Compiling in the T+ state (pointers obtained using the @ operator are typed)
SAFEDIVIDE_ON Compiling in the U+ state (save FDIV instruction through RTL emulation)
VARSTRINGCHECKS_ON Compiling in the V+ state (type checking of shortstrings)
STACKFRAMES_ON Compiling in the W+ state (generation of stack frames)
EXTENDEDSYNTAX_ON Compiling in the X+ state (Delphi extended syntax enabled)


About

Contribute to this help topic

This documentation wiki is based on the collaborative effort of Project JEDI users. Your edits are welcome in order to improve documentation quality: edit this page