[Release][Bugfix] Fix bigunsignedint numeric_limits for clang/libc++
The std::numeric_limits specialization for bigunsignedint requires access to the internal state of bigunsignedint. Previously, the correct specialization of std::numeric_limits was a friend of bigunsignedint, but that creates problems on recent versions of clang with the alternative libc++ library, because that library declares the base template of std::numeric_limits as a class and clang subsequently complains if the friend declaration uses 'struct'. Unfortunately, libstdc++ uses a struct, making it impossible to keep clang happy for both standard libraries. So we introduce a helper class that provides access to the internal state and which now becomes a friend of bigunsignedint. The numeric_limits specialization inherits from the helper to use it.
Loading
Please register or sign in to comment