Nix 2.93.3
Lix: A modern, delicious implementation of the Nix package manager; unstable internal interfaces
Loading...
Searching...
No Matches
serve-protocol-impl.hh File Reference
#include "lix/libstore/serve-protocol.hh"
#include "lix/libstore/length-prefixed-protocol-helper.hh"

Go to the source code of this file.

Macros

#define SERVE_USE_LENGTH_PREFIX_SERIALISER(TEMPLATE, T)
#define COMMA_   ,

Detailed Description

Template implementations (as opposed to mere declarations).

This file is an exmample of the "impl.hh" pattern. See the contributing guide.

Macro Definition Documentation

◆ SERVE_USE_LENGTH_PREFIX_SERIALISER

#define SERVE_USE_LENGTH_PREFIX_SERIALISER ( TEMPLATE,
T )
Value:
TEMPLATE T ServeProto::Serialise< T >::read(const Store & store, ServeProto::ReadConn conn) \
{ \
return LengthPrefixedProtoHelper<ServeProto, T >::read(store, conn); \
} \
/* NOLINTNEXTLINE(bugprone-macro-parentheses) */ \
TEMPLATE [[nodiscard]] WireFormatGenerator ServeProto::Serialise< T >::write(const Store & store, ServeProto::WriteConn conn, const T & t) \
{ \
return LengthPrefixedProtoHelper<ServeProto, T >::write(store, conn, t); \
}