![]() |
Nix 2.36.0
Nix, the purely functional package manager; unstable internal interfaces
|
#include <worker-protocol.hh>
Classes | |
| struct | Number |
Public Types | |
| using | Feature = std::string |
| using | FeatureSet = std::set<Feature, std::less<>> |
Public Member Functions | |
| bool | operator== (const Version &) const =default |
| std::partial_ordering | operator<=> (const Version &other) const |
Public Attributes | |
| struct nix::WorkerProto::Version::Number | number |
| FeatureSet | features = {} |
Version type for the protocol.
This bundles the protocol version number with the negotiated feature set. The version number has a total ordering, but the full Version (number + features) only has a partial ordering, so there is no operator<=> on Version itself — callers must compare .number explicitly.
| std::partial_ordering nix::WorkerProto::Version::operator<=> | ( | const Version & | other | ) | const |
Partial ordering: v1 <= v2 iff v1.number <= v2.number AND v1.features is a subset of v2.features. Two versions with incomparable feature sets are unordered.