mirror of
https://github.com/NixOS/nix.git
synced 2025-11-16 15:32:43 +01:00
"newtype" BuildableReq
This makes for better types errors and allows us to give it methods.
This commit is contained in:
parent
4fe41c6db3
commit
9dfb97c987
8 changed files with 24 additions and 16 deletions
|
|
@ -55,12 +55,12 @@ void write(const Store & store, Sink & out, const ContentAddress & ca)
|
|||
BuildableReq read(const Store & store, Source & from, Phantom<BuildableReq> _)
|
||||
{
|
||||
auto s = readString(from);
|
||||
return parseBuildableReq(store, s);
|
||||
return BuildableReq::parse(store, s);
|
||||
}
|
||||
|
||||
void write(const Store & store, Sink & out, const BuildableReq & req)
|
||||
{
|
||||
out << to_string(store, req);
|
||||
out << req.to_string(store);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue