Mercurial > hg > CbC > CbC_llvm
diff libc/utils/benchmarks/JSON.cpp @ 173:0572611fdcc8 llvm10 llvm12
reorgnization done
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 25 May 2020 11:55:54 +0900 |
parents | 1d019706d866 |
children |
line wrap: on
line diff
--- a/libc/utils/benchmarks/JSON.cpp Mon May 25 11:50:15 2020 +0900 +++ b/libc/utils/benchmarks/JSON.cpp Mon May 25 11:55:54 2020 +0900 @@ -1,4 +1,4 @@ -//===-------- JSON serialization routines ---------------------------------===// +//===-- JSON serialization routines ---------------------------------------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. @@ -17,9 +17,11 @@ #include "llvm/Support/ErrorHandling.h" #include "llvm/Support/JSON.h" #include "llvm/Support/MathExtras.h" + #include <chrono> #include <limits> #include <memory> +#include <string> #include <vector> namespace llvm { @@ -48,7 +50,7 @@ static Error fromJson(const json::Value &V, std::string &Out) { if (auto S = V.getAsString()) { - Out = *S; + Out = std::string(*S); return Error::success(); } return createStringError(errc::io_error, "Can't parse String");