Simplify module API (#4840)
* Simplify module API Signed-off-by: Miko <110693261+mikomikotaishi@users.noreply.github.com> * Forgot missing newline Signed-off-by: Miko <110693261+mikomikotaishi@users.noreply.github.com> --------- Signed-off-by: Miko <110693261+mikomikotaishi@users.noreply.github.com>
This commit is contained in:
2 files changed
+6
-13
No files matched your search
@@ -25,6 +25,7 @@ json data = json::parse(f);
|
|||||||
|
|
||||||
## Modules do not export macros
|
## Modules do not export macros
|
||||||
It should be noted that as modules do not export macros, the `nlohmann.json` module will not export any macros, but rather only the following symbols:
|
It should be noted that as modules do not export macros, the `nlohmann.json` module will not export any macros, but rather only the following symbols:
|
||||||
|
|
||||||
- `nlohmann::adl_serializer`
|
- `nlohmann::adl_serializer`
|
||||||
- `nlohmann::basic_json`
|
- `nlohmann::basic_json`
|
||||||
- `nlohmann::json`
|
- `nlohmann::json`
|
||||||
|
|||||||
+5
-13
@@ -5,18 +5,10 @@ module;
|
|||||||
export module nlohmann.json;
|
export module nlohmann.json;
|
||||||
|
|
||||||
export namespace nlohmann {
|
export namespace nlohmann {
|
||||||
template <typename T = void, typename SFINAE = void>
|
using ::nlohmann::adl_serializer;
|
||||||
using adl_serializer = ::nlohmann::adl_serializer<T, SFINAE>;
|
using ::nlohmann::basic_json;
|
||||||
|
using ::nlohmann::json;
|
||||||
using basic_json = ::nlohmann::basic_json<>;
|
using ::nlohmann::json_pointer;
|
||||||
|
|
||||||
using json = ::nlohmann::json;
|
|
||||||
|
|
||||||
template <typename RefStringType>
|
|
||||||
using json_pointer = ::nlohmann::json_pointer<RefStringType>;
|
|
||||||
|
|
||||||
using ::nlohmann::ordered_json;
|
using ::nlohmann::ordered_json;
|
||||||
|
using ::nlohmann::ordered_map;
|
||||||
template <class Key, class T, class IgnoredLess, class Allocator>
|
|
||||||
using ordered_map = ::nlohmann::ordered_map<Key, T, IgnoredLess, Allocator>;
|
|
||||||
} // namespace nlohmann
|
} // namespace nlohmann
|
||||||
Reference in new issue
Block a user