diff options
| author | 2018-09-16 20:05:51 +0200 | |
|---|---|---|
| committer | 2018-10-02 15:30:48 +0200 | |
| commit | 4d139943f2407144d5f8e3dc5a673f24850d43d0 (patch) | |
| tree | be24285a32c2b72b9756b69fd614f3d45c70ff41 /src/web_service/json.h | |
| parent | Add submodules (diff) | |
| download | yuzu-4d139943f2407144d5f8e3dc5a673f24850d43d0.tar.gz yuzu-4d139943f2407144d5f8e3dc5a673f24850d43d0.tar.xz yuzu-4d139943f2407144d5f8e3dc5a673f24850d43d0.zip | |
Port web_service from Citra
Diffstat (limited to 'src/web_service/json.h')
| -rw-r--r-- | src/web_service/json.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/web_service/json.h b/src/web_service/json.h new file mode 100644 index 000000000..88b31501e --- /dev/null +++ b/src/web_service/json.h | |||
| @@ -0,0 +1,18 @@ | |||
| 1 | // Copyright 2018 Citra Emulator Project | ||
| 2 | // Licensed under GPLv2 or any later version | ||
| 3 | // Refer to the license.txt file included. | ||
| 4 | |||
| 5 | #pragma once | ||
| 6 | |||
| 7 | // This hack is needed to support json.hpp on platforms where the C++17 stdlib | ||
| 8 | // lacks std::string_view. See https://github.com/nlohmann/json/issues/735. | ||
| 9 | // clang-format off | ||
| 10 | #if !__has_include(<string_view>) && __has_include(<experimental/string_view>) | ||
| 11 | # include <experimental/string_view> | ||
| 12 | # define string_view experimental::string_view | ||
| 13 | # include <json.hpp> | ||
| 14 | # undef string_view | ||
| 15 | #else | ||
| 16 | # include <json.hpp> | ||
| 17 | #endif | ||
| 18 | // clang-format on | ||