mirror of
https://github.com/nlohmann/json.git
synced 2024-12-04 22:49:02 +08:00
added missing typename (required by clang/gcc)
This commit is contained in:
parent
4d079d135e
commit
e2f0e8b945
@ -2422,7 +2422,7 @@ class basic_json
|
|||||||
template<typename ReferenceType, typename ThisType>
|
template<typename ReferenceType, typename ThisType>
|
||||||
static ReferenceType get_ref_impl(ThisType& obj)
|
static ReferenceType get_ref_impl(ThisType& obj)
|
||||||
{
|
{
|
||||||
using PointerType = std::add_pointer<ReferenceType>::type;
|
using PointerType = typename std::add_pointer<ReferenceType>::type;
|
||||||
// delegate the call to get_ptr<>()
|
// delegate the call to get_ptr<>()
|
||||||
auto ptr = obj.get_ptr<PointerType>();
|
auto ptr = obj.get_ptr<PointerType>();
|
||||||
if (ptr) return *ptr;
|
if (ptr) return *ptr;
|
||||||
|
@ -2422,7 +2422,7 @@ class basic_json
|
|||||||
template<typename ReferenceType, typename ThisType>
|
template<typename ReferenceType, typename ThisType>
|
||||||
static ReferenceType get_ref_impl(ThisType& obj)
|
static ReferenceType get_ref_impl(ThisType& obj)
|
||||||
{
|
{
|
||||||
using PointerType = std::add_pointer<ReferenceType>::type;
|
using PointerType = typename std::add_pointer<ReferenceType>::type;
|
||||||
// delegate the call to get_ptr<>()
|
// delegate the call to get_ptr<>()
|
||||||
auto ptr = obj.get_ptr<PointerType>();
|
auto ptr = obj.get_ptr<PointerType>();
|
||||||
if (ptr) return *ptr;
|
if (ptr) return *ptr;
|
||||||
|
Loading…
Reference in New Issue
Block a user