From 3dcfa8307627774430926300f13ea31899f93f77 Mon Sep 17 00:00:00 2001 From: Niels Lohmann Date: Fri, 16 Oct 2026 08:22:12 +0200 Subject: [PATCH] Follow the renames from the review of the view builder The review of #5620 renamed document_data's tape/tape_size/tape_cap to nodes/node_count/node_capacity and made the decode arena a std::vector; adapt the code of this change to it. Signed-off-by: Niels Lohmann --- include/nlohmann/json_view.hpp | 2 +- single_include/nlohmann/json_view.hpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/nlohmann/json_view.hpp b/include/nlohmann/json_view.hpp index da9cb05be..fc5c8dd56 100644 --- a/include/nlohmann/json_view.hpp +++ b/include/nlohmann/json_view.hpp @@ -713,7 +713,7 @@ class basic_json_view /// decoded strings); the estimate sizes the output buffer of dump() std::size_t source_extent() const noexcept { - const node* const end = m_doc->tape + m_doc->tape_size; + const node* const end = m_doc->nodes + m_doc->node_count; if ((m_node->flags & detail::view::node_flags::storage) != 0) { return m_node->len; diff --git a/single_include/nlohmann/json_view.hpp b/single_include/nlohmann/json_view.hpp index f83b1c92d..5968845ca 100644 --- a/single_include/nlohmann/json_view.hpp +++ b/single_include/nlohmann/json_view.hpp @@ -4604,7 +4604,7 @@ class basic_json_view /// decoded strings); the estimate sizes the output buffer of dump() std::size_t source_extent() const noexcept { - const node* const end = m_doc->tape + m_doc->tape_size; + const node* const end = m_doc->nodes + m_doc->node_count; if ((m_node->flags & detail::view::node_flags::storage) != 0) { return m_node->len;