[ox] Make OC and Claw writers take const values
This commit is contained in:
4
deps/ox/src/ox/oc/write.hpp
vendored
4
deps/ox/src/ox/oc/write.hpp
vendored
@@ -24,7 +24,7 @@ namespace ox {
|
||||
|
||||
class OrganicClawWriter {
|
||||
|
||||
friend Result<Buffer> writeOC(auto &val) noexcept;
|
||||
friend Result<Buffer> writeOC(const auto &val) noexcept;
|
||||
|
||||
protected:
|
||||
Json::Value m_json;
|
||||
@@ -248,7 +248,7 @@ Error OrganicClawWriter::field(const char *key, UnionView<U, force> val) noexcep
|
||||
return OxError(0);
|
||||
}
|
||||
|
||||
Result<Buffer> writeOC(auto &val) noexcept {
|
||||
Result<Buffer> writeOC(const auto &val) noexcept {
|
||||
OrganicClawWriter writer;
|
||||
ModelHandlerInterface handler(&writer);
|
||||
oxReturnError(model(&handler, &val));
|
||||
|
Reference in New Issue
Block a user