Lines Matching full:json
2 #include <nlohmann/json.hpp>
4 using json = nlohmann::json;
8 // correct JSON pointers
9 json::json_pointer p1;
10 json::json_pointer p2("");
11 json::json_pointer p3("/");
12 json::json_pointer p4("//");
13 json::json_pointer p5("/foo/bar");
14 json::json_pointer p6("/foo/bar/-");
15 json::json_pointer p7("/foo/~0");
16 json::json_pointer p8("/foo/~1");
18 // error: JSON pointer does not begin with a slash
21 json::json_pointer p9("foo");
23 catch (json::parse_error& e)
28 // error: JSON pointer uses escape symbol ~ not followed by 0 or 1
31 json::json_pointer p10("/foo/~");
33 catch (json::parse_error& e)
38 // error: JSON pointer uses escape symbol ~ not followed by 0 or 1
41 json::json_pointer p11("/foo/~3");
43 catch (json::parse_error& e)