]> de.git.xonotic.org Git - xonotic/gmqcc.git/blobdiff - gmqcc.ini.example
Arithmetic exception flag and a plethora of tests.
[xonotic/gmqcc.git] / gmqcc.ini.example
index acff3b3daaecadc5868f60b1363d71b4c5f8040d..f7f391396c9d61dc96f0f4e86a388a4294db9799 100644 (file)
     FTEPP_PREDEFS = false
 
 
+    #Enable math constant definitions. This only works in combination
+    #with '-fftepp' and is currently not included by '-std=fteqcc'.
+    #The following macros will be added:
+    #
+    # M_E
+    # M_LOG2E
+    # M_LOG10E
+    # M_LN2
+    # M_LN10
+    # M_PI
+    # M_PI_2
+    # M_PI_4
+    # M_1_PI
+    # M_2_PI
+    # M_2_SQRTPI
+    # M_SQRT2
+    # M_SQRT1_2
+    # M_TAU
+
+    FTEPP_MATHDEFS = false
+
+
     #Allow switch cases to use non constant variables.
 
     RELAXED_SWITCH = true
     SORT_OPERANDS = false
 
 
+    #Turn on arithmetic exception tests in the compiler. In constant expressions
+    #which trigger exceptions like division by zero, overflow, underflow, etc,
+    #the following flag will produce diagnostics for what triggered that
+    #exception.
+    ARITHMETIC_EXCEPTIONS = false
 
 [warnings]
     #Generate a warning about variables which are declared but never
     DIRECTIVE_INMACRO = true
 
 
+    #When using a function that is not explicitly defined, the compiler
+    #will search its intrinsics table for something that matches that
+    #function name by appending "__builtin_" to it. This behaviour may
+    #be unexpected, so enabling this will produce a diagnostic when
+    #such a function is resolved to a builtin.
+
+    BUILTINS = true
+
+
+    #When comparing an inexact value such as `1.0/3.0' the result is
+    #pathologically wrong. Enabling this will trigger a compiler warning
+    #on such expressions.
+    INEXACT_COMPARES = true
+
 
 [optimizations]
     #Some general peephole optimizations. For instance the code `a = b