Opened 4 years ago

Closed 4 years ago

#830 closed defect (fixed)

GDE/MUSCLE/src/subfams.cpp redefines INFINITY

Reported by: guest Owned by: westram
Priority: normal Milestone:
Component: GDE Version: arb-6.0.6
Keywords: Cc:

Description

Hi, arb 6.0.6 fails to build on macOS 10.15. The error is in this file:

browser:trunk/GDE/MUSCLE/src/subfams.cpp

It tries to define INFINITY which has already been defined by the system math.h header.

The error is:

src/subfams.cpp:4:13: error: functions that differ only in their return type cannot be overloaded
const float INFINITY = float(1e29);
      ~~~~~ ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include/math.h:68:21: note: expanded from macro 'INFINITY'
#define INFINITY    HUGE_VALF
                    ^
/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk/usr/include/math.h:58:28: note: expanded from macro 'HUGE_VALF'
#   define    HUGE_VALF    __builtin_huge_valf()
                           ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../include/c++/v1/limits:332:90: note: previous implicit declaration is here
    _LIBCPP_INLINE_VISIBILITY static _LIBCPP_CONSTEXPR type infinity() _NOEXCEPT {return __builtin_huge_valf();}
                                                                                         ^
1 error generated.

This has previously been reported here: https://github.com/arb-project/homebrew-arb/issues/4

And now here: https://trac.macports.org/ticket/61296

Change History (3)

comment:1 Changed 4 years ago by westram

  • Owner changed from devel to westram
  • Status changed from new to _started

comment:2 Changed 4 years ago by westram

  • Status changed from _started to assigned

fixed by [18606]. not confirmed yet.

Last edited 4 years ago by westram (previous) (diff)

comment:3 Changed 4 years ago by westram

  • Resolution set to fixed
  • Status changed from assigned to closed
Note: See TracTickets for help on using tickets.