error message for reusing multiple hashes for package

This commit is contained in:
Gregory Becker 2021-11-04 18:39:14 -07:00 committed by Todd Gamblin
parent ac1e05fe1b
commit 5efa76a033

View File

@ -790,7 +790,8 @@ no_flags(Package, FlagType)
% Installed packages
%-----------------------------------------------------------------------------
% the solver is free to choose at most one installed hash for each package
{ hash(Package, Hash) : installed_hash(Package, Hash) } 1 :- node(Package).
{ hash(Package, Hash) : installed_hash(Package, Hash) } 1
:- node(Package), error("Internal error: package must resolve to at most one hash").
% if a hash is selected, we impose all the constraints that implies
impose(Hash) :- hash(Package, Hash).