Skip to content

Commit 58d99ca

Browse files
authored
Use the canonical #include location for json.hpp (google#55)
use the canonical #include location for json.hpp
1 parent cef3e04 commit 58d99ca

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

CMakeLists.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,6 @@ message(STATUS "${fuzztest_BINARY_DIR}: ${${fuzztest_BINARY_DIR}}")
9191
include_directories(
9292
include/minja
9393
${json_SOURCE_DIR}/include
94-
${json_SOURCE_DIR}/include/nlohmann
9594
)
9695

9796
add_subdirectory(examples)

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ It is **not general purpose**: it includes just what’s needed for actual chat
3131

3232
## Usage:
3333

34-
This library is header-only: just copy the header(s) you need, make sure to use a compiler that handles C++17 and you're done. Oh, and get [nlohmann::json](https://github.com/nlohmann/json)'s `json.hpp` in your include path.
34+
This library is header-only: just copy the header(s) you need, make sure to use a compiler that handles C++17 and you're done. Oh, and get [nlohmann::json](https://github.com/nlohmann/json) in your include path.
3535

3636
See API in [minja/minja.hpp](./include/minja/minja.hpp) and [minja/chat-template.hpp](./include/minja/chat-template.hpp) (experimental).
3737

include/minja/chat-template.hpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,12 @@
99
#pragma once
1010

1111
#include "minja.hpp"
12-
#include <json.hpp>
12+
1313
#include <string>
1414
#include <vector>
1515

16+
#include <nlohmann/json.hpp>
17+
1618
using json = nlohmann::ordered_json;
1719

1820
namespace minja {

include/minja/minja.hpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,8 @@
1616
#include <stdexcept>
1717
#include <sstream>
1818
#include <unordered_set>
19-
#include <json.hpp>
19+
20+
#include <nlohmann/json.hpp>
2021

2122
using json = nlohmann::ordered_json;
2223

0 commit comments

Comments
 (0)