[#nlohmann-basic_json-00-2constructor-00] = xref:nlohmann.adoc[nlohmann]::xref:nlohmann/basic_json-00.adoc[basic_json]::basic_json :relfileprefix: ../../ :mrdocs: create a JSON value from compatible types == Synopsis Declared in `<nlohmann/json.hpp>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- template< typename CompatibleType, typename U = detail::uncvref_t<CompatibleType>> requires !detail::is_basic_json<U>::value && detail::is_compatible_type<basic_json_t, U>::value basic_json(CompatibleType&& val) noexcept(noexcept(JSONSerializer<U, void>::to_json(std::declval<basic_json_t &>(), std::forward<CompatibleType>(val)))); ---- == Parameters [cols=2] |=== | Name | Description | *val* | The object to move construct from |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#