From c36142d645ddbc5d7db5852fb652bd1b34b20bc0 Mon Sep 17 00:00:00 2001 From: Andrew Nolte Date: Sat, 3 May 2025 09:17:23 -0400 Subject: [PATCH] Allow passing yyjson flags in the read(istream) method (#425) --- include/rfl/json/read.hpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/rfl/json/read.hpp b/include/rfl/json/read.hpp index f0dda4e8..7d3d3129 100644 --- a/include/rfl/json/read.hpp +++ b/include/rfl/json/read.hpp @@ -45,10 +45,10 @@ Result> read( /// Parses an object from a stringstream. template -auto read(std::istream& _stream) { +auto read(std::istream& _stream, const yyjson_read_flag _flag = 0) { const auto json_str = std::string(std::istreambuf_iterator(_stream), std::istreambuf_iterator()); - return read(json_str); + return read(json_str, _flag); } } // namespace json