From 11aad01e377c0fd59fcecc60f0a64c545b37013f Mon Sep 17 00:00:00 2001 From: Andrew Nolte Date: Fri, 2 May 2025 17:03:53 -0400 Subject: [PATCH] Allow passing yyjson flags in the read(istream) method --- 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