Right way to turn FPDOC_MATH on? lazarus / 11-Options ---------------------------------------------------------------------- EganSolo · 2016-09-11 21:34 So I've got a package that references MinExtended and MaxExtended. These constants are defined in the Math unit and they are available only when the FPOC_MATH conditional is turned on. I know I could add this as a custom option in my project, but wanted to know if there is a pre-set switch I could enable without having to mess around with FPOC_MATH? Thanks! ---------------------------------------------------------------------- Thaddy · 2016-09-12 06:32 Not as far as I know. {$DEFINE FPDOC_MATH} is in my opinion a preset switch... ---------------------------------------------------------------------- marcov · 2016-09-12 07:01 fpdoc* conditionals are only true during documentation building, never during normal compilation. ---------------------------------------------------------------------- EganSolo · 2016-09-12 07:08 Maybe I've muddled the field by not asking the right question... What I want is to enable MinExtended and MaxExtended. These two constants are enabled in the Math unit only if FPDOC_MATH is enabled as seen in the fragment taken from the top of the Math unit. So, really, what I need to know is how to enable these constants? Thanks! Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i  {$IFDEF FPDOC_MATH}{$DEFINE FPC_HAS_TYPE_SINGLE}{$DEFINE FPC_HAS_TYPE_DOUBLE}[b]{$DEFINE FPC_HAS_TYPE_EXTENDED}[/b]{$DEFINE FPC_HAS_TYPE_COMP}[snip...]{$ENDIF} [snip...] [b]{$ifdef FPC_HAS_TYPE_EXTENDED}[/b]    const      MinExtended  =  3.4e-4932;    MaxExtended  =  1.1e+4932;{$endif FPC_HAS_TYPE_EXTENDED} ---------------------------------------------------------------------- marcov · 2016-09-12 07:53 Ah, no FPC_HAS_TYPE_EXTENDED is enabled by the compiler if the compiler supports the type. The documentation tool however doesn't have the info what the compiler defines, so this is used to fake this. Basically if the constants are not visible, your platform does not have support for extended and extended is an alias for double.  (extended is a x87 specific type) Simply enabling the ifdef is useless since then the compiler doesn't support the range ( exponent 10^4000 something) that the constants have, so it won't compile anyway. ---------------------------------------------------------------------- EganSolo · 2016-09-12 19:12 I see, thanks for the clarification. Out of curiosity, which processor supports the extended type? I've got an i7-4790 CPU @3.60 GHZ 4 cores. Doesn't it qualify? Also, if I declare a variable of type extended, Laz doesn't complain. Why is it then that it complains when I try to access MinExtended and MaxExtended? Is it that these constants were not also declared in case Extended is not supported? ---------------------------------------------------------------------- EganSolo · 2016-09-12 19:16 One more thing... I've gone ahead and (Temporarily) declared the following constants in my code: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i const  MaxExtended  =  1.1e+4932;  MinExtended  =  3.4e-4932; And Lazarus is not complaining about it. If my system is not able to support extended, shouldn't Laz complain about the range of these constants?