Bug #1426

GCC 5.3 when -std=c++11 dosen't see isnan isinf functions

Added by Zbigniew Rebacz over 3 years ago. Updated over 3 years ago.

Status:ApprovedStart date:04/23/2016
Priority:UrgentDue date:
Assignee:-% Done:

0%

Category:CoreSpent time:-
Target version:Release 2017.1

Description

Tested with Kubuntu 16.04 and GCC 5.3. In default mode everything works fine.

It seems that we have got compilation issue:


In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.icpp:1:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsNaN(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: error: ‘isnan’ was not declared in this scope
 inline bool IsNaN(double d)        { return isnan(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.icpp:1:
/usr/include/c++/5/cmath:641:5: note:   ‘std::isnan’
     isnan(_Tp __x)
     ^
In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.icpp:1:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsInf(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: error: ‘isinf’ was not declared in this scope
 inline bool IsInf(double d)        { return isinf(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.icpp:1:
/usr/include/c++/5/cmath:621:5: note:   ‘std::isinf’
     isinf(_Tp __x)
     ^
In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChGtk0.cpp:1:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsNaN(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: error: ‘isnan’ was not declared in this scope
 inline bool IsNaN(double d)        { return isnan(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChGtk0.cpp:1:
/usr/include/c++/5/cmath:641:5: note:   ‘std::isnan’
     isnan(_Tp __x)
     ^
In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChGtk0.cpp:1:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsInf(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: error: ‘isinf’ was not declared in this scope
 inline bool IsInf(double d)        { return isinf(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChGtk0.cpp:1:
/usr/include/c++/5/cmath:621:5: note:   ‘std::isinf’
     isinf(_Tp __x)
     ^
In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChWin32.cpp:1:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsNaN(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: error: ‘isnan’ was not declared in this scope
 inline bool IsNaN(double d)        { return isnan(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChWin32.cpp:1:
/usr/include/c++/5/cmath:641:5: note:   ‘std::isnan’
     isnan(_Tp __x)
     ^
In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChWin32.cpp:1:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsInf(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: error: ‘isinf’ was not declared in this scope
 inline bool IsInf(double d)        { return isinf(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChWin32.cpp:1:
/usr/include/c++/5/cmath:621:5: note:   ‘std::isinf’
     isinf(_Tp __x)
     ^
In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChGtk.cpp:1:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsNaN(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: error: ‘isnan’ was not declared in this scope
 inline bool IsNaN(double d)        { return isnan(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChGtk.cpp:1:
/usr/include/c++/5/cmath:641:5: note:   ‘std::isnan’
     isnan(_Tp __x)
     ^
In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChGtk.cpp:1:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsInf(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: error: ‘isinf’ was not declared in this scope
 inline bool IsInf(double d)        { return isinf(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/ChGtk.cpp:1:
/usr/include/c++/5/cmath:621:5: note:   ‘std::isinf’
     isinf(_Tp __x)
     ^
In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/LabelBase.cpp:1,
                 from /home/klugier/.upp/_out/examples/CtrlLib/GCC.Debug.Debug_Full.Gui.Mt.Shared/$blitz.cpp:3:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsNaN(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: error: ‘isnan’ was not declared in this scope
 inline bool IsNaN(double d)        { return isnan(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:344:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/LabelBase.cpp:1,
                 from /home/klugier/.upp/_out/examples/CtrlLib/GCC.Debug.Debug_Full.Gui.Mt.Shared/$blitz.cpp:3:
/usr/include/c++/5/cmath:641:5: note:   ‘std::isnan’
     isnan(_Tp __x)
     ^
In file included from /home/klugier/upp/uppsrc/Core/Core.h:246:0,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/LabelBase.cpp:1,
                 from /home/klugier/.upp/_out/examples/CtrlLib/GCC.Debug.Debug_Full.Gui.Mt.Shared/$blitz.cpp:3:
/home/klugier/upp/uppsrc/Core/Defs.h: In function ‘bool Upp::IsInf(double)’:
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: error: ‘isinf’ was not declared in this scope
 inline bool IsInf(double d)        { return isinf(d); }
                                                    ^
/home/klugier/upp/uppsrc/Core/Defs.h:345:52: note: suggested alternative:
In file included from /usr/include/c++/5/random:38:0,
                 from /usr/include/c++/5/bits/stl_algo.h:66,
                 from /usr/include/c++/5/algorithm:62,
                 from /home/klugier/upp/uppsrc/Core/Core.h:219,
                 from /home/klugier/upp/uppsrc/Draw/Draw.h:6,
                 from /home/klugier/upp/uppsrc/RichText/RichText.h:4,
                 from /home/klugier/upp/uppsrc/CtrlCore/CtrlCore.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/CtrlLib.h:4,
                 from /home/klugier/upp/uppsrc/CtrlLib/LabelBase.cpp:1,
                 from /home/klugier/.upp/_out/examples/CtrlLib/GCC.Debug.Debug_Full.Gui.Mt.Shared/$blitz.cpp:3:
/usr/include/c++/5/cmath:621:5: note:   ‘std::isinf’
     isinf(_Tp __x)
     ^

History

#1 Updated by Zbigniew Rebacz over 3 years ago

Attention adding std:: before this two method fix this issue.

#2 Updated by Zbigniew Rebacz over 3 years ago

  • Status changed from New to Approved

Also available in: Atom PDF