Planeshift
fpconfig.h
Go to the documentation of this file.
1 /***************************************************************************\
2 |* Function Parser for C++ v4.5.2 *|
3 |*-------------------------------------------------------------------------*|
4 |* Copyright: Juha Nieminen *|
5 |* *|
6 |* This library is distributed under the terms of the *|
7 |* GNU Lesser General Public License version 3. *|
8 |* (See lgpl.txt and gpl.txt for the license text.) *|
9 \***************************************************************************/
10 
11 // Configuration file
12 // ------------------
13 
14 /* NOTE:
15  This file is for the internal use of the function parser only.
16  You don't need to include this file in your source files, just
17  include "fparser.hh".
18 */
19 
20 
21 /* Uncomment any of these lines or define them in your compiler settings
22  to enable the correspondent version of the parser. (These are disabled
23  by default because they rely on C99 functions, and non-standard libraries
24  in the case pf MPFR and GMP, and they make compiling needlessly slower
25  and the resulting binary needlessly larger if they are not used in the
26  program.)
27 */
28 //#define FP_SUPPORT_FLOAT_TYPE
29 //#define FP_SUPPORT_LONG_DOUBLE_TYPE
30 //#define FP_SUPPORT_LONG_INT_TYPE
31 //#define FP_SUPPORT_MPFR_FLOAT_TYPE
32 //#define FP_SUPPORT_GMP_INT_TYPE
33 //#define FP_SUPPORT_COMPLEX_DOUBLE_TYPE
34 //#define FP_SUPPORT_COMPLEX_FLOAT_TYPE
35 //#define FP_SUPPORT_COMPLEX_LONG_DOUBLE_TYPE
36 
37 /* If you are using FunctionParser_ld or FunctionParser_cld and your compiler
38  supports the strtold() function, you should uncomment the following line.
39  */
40 //#define FP_USE_STRTOLD
41 
42 
43 /* Uncomment this line or define it in your compiler settings if you want
44  to disable compiling the basic double version of the library, in case
45  one of the above types is used but not the double type. (If the double
46  type is not used, then disabling it makes compiling faster and the
47  resulting binary smaller.)
48  */
49 //#define FP_DISABLE_DOUBLE_TYPE
50 
51 /* Uncomment this line or define it in your compiler settings to make the
52  parser use C++11 math functions. (Note that these may not be supported
53  by all compilers.)
54 */
55 //#define FP_SUPPORT_CPLUSPLUS11_MATH_FUNCS
56 
57 /*
58  Whether to use shortcut evaluation for the & and | operators:
59 */
60 #ifndef FP_DISABLE_SHORTCUT_LOGICAL_EVALUATION
61 #define FP_ENABLE_SHORTCUT_LOGICAL_EVALUATION
62 #endif
63 
64 /*
65  Comment out the following lines out if you are not going to use the
66  optimizer and want a slightly smaller library. The Optimize() method
67  can still be called, but it will not do anything.
68  If you are unsure, just leave it. It won't slow down the other parts of
69  the library.
70 */
71 #ifndef FP_NO_SUPPORT_OPTIMIZER
72 #define FP_SUPPORT_OPTIMIZER
73 #endif
74 
75 #if defined(FP_SUPPORT_COMPLEX_DOUBLE_TYPE) || defined(FP_SUPPORT_COMPLEX_FLOAT_TYPE) || defined(FP_SUPPORT_COMPLEX_LONG_DOUBLE_TYPE)
76 #define FP_SUPPORT_COMPLEX_NUMBERS
77 #endif
78 
79 
80 /*
81  No member function of FunctionParser is thread-safe. Most prominently,
82  Eval() is not thread-safe. By uncommenting one of these lines the Eval()
83  function can be made thread-safe at the cost of a possible small overhead.
84  The second version requires that the compiler supports the alloca() function,
85  which is not standard, but is faster.
86  */
87 //#define FP_USE_THREAD_SAFE_EVAL
88 //#define FP_USE_THREAD_SAFE_EVAL_WITH_ALLOCA