Skip to content

Commit

Permalink
Detect correctly pointer-to-const
Browse files Browse the repository at this point in the history
The intention of the current code is to detect a pointer-to-const but instead it is detecting a const-pointer. See nlohmann#134
  • Loading branch information
dariomt committed Oct 16, 2015
1 parent 57de1d6 commit b342e12
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/json.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -2385,7 +2385,7 @@ class basic_json
template<typename PointerType, typename
std::enable_if<
std::is_pointer<PointerType>::value
and std::is_const<PointerType>::value
and std::is_const< typename std::remove_pointer<PointerType>::type >::value
, int>::type = 0>
const PointerType get_ptr() const noexcept
{
Expand Down

0 comments on commit b342e12

Please sign in to comment.