diff --git a/src/json.hpp b/src/json.hpp index fbb7b502..3aad611b 100644 --- a/src/json.hpp +++ b/src/json.hpp @@ -410,7 +410,7 @@ class basic_json { Allocator alloc; m_value.object = alloc.allocate(1); - alloc.construct(m_value.object, value.begin(), value.end()); + alloc.construct(m_value.object, std::begin(value), std::end(value)); } /// create an array (explicit) @@ -438,7 +438,7 @@ class basic_json { Allocator alloc; m_value.array = alloc.allocate(1); - alloc.construct(m_value.array, value.begin(), value.end()); + alloc.construct(m_value.array, std::begin(value), std::end(value)); } /// create a string (explicit) @@ -3067,7 +3067,8 @@ class basic_json @see */ - inline static string_t to_unicode(const size_t codepoint1, const size_t codepoint2 = 0) + inline static string_t to_unicode(const size_t codepoint1, + const size_t codepoint2 = 0) { string_t result; @@ -3095,7 +3096,7 @@ class basic_json if (codepoint <= 0x7f) { - // 1-byte characters: 0xxxxxxx (ASCI) + // 1-byte characters: 0xxxxxxx (ASCII) result.append(1, static_cast(codepoint)); } else if (codepoint <= 0x7ff) diff --git a/src/json.hpp.re2c b/src/json.hpp.re2c index 9226dc13..0829e9b1 100644 --- a/src/json.hpp.re2c +++ b/src/json.hpp.re2c @@ -410,7 +410,7 @@ class basic_json { Allocator alloc; m_value.object = alloc.allocate(1); - alloc.construct(m_value.object, value.begin(), value.end()); + alloc.construct(m_value.object, std::begin(value), std::end(value)); } /// create an array (explicit) @@ -438,7 +438,7 @@ class basic_json { Allocator alloc; m_value.array = alloc.allocate(1); - alloc.construct(m_value.array, value.begin(), value.end()); + alloc.construct(m_value.array, std::begin(value), std::end(value)); } /// create a string (explicit)