From 8fdd20cdda61b9f168028e8a965e5dc2399649f7 Mon Sep 17 00:00:00 2001 From: silverweed Date: Sun, 20 Sep 2015 16:15:55 +0200 Subject: [PATCH] Overload parse() to accept an rvalue reference --- src/json.hpp.re2c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/json.hpp.re2c b/src/json.hpp.re2c index af8ef8b7..d62d6505 100644 --- a/src/json.hpp.re2c +++ b/src/json.hpp.re2c @@ -4471,6 +4471,11 @@ class basic_json return parser(i, cb).parse(); } + static basic_json parse(std::istream&& i, parser_callback_t cb = nullptr) + { + return parser(i, cb).parse(); + } + /*! @brief deserialize from stream