internal/pkg: deduplicate DCE by ident

This eliminates edge cases where target artifacts do not compare equal.

Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
2026-05-13 00:14:15 +09:00
parent 8f3c22896a
commit 487a03b5a3
2 changed files with 31 additions and 18 deletions

View File

@@ -1515,6 +1515,8 @@ func TestDependencyCureError(t *testing.T) {
makeIdent := func(ident ...byte) pkg.Artifact {
var a overrideIdent
copy(a.id[:], ident)
// does not compare equal
a.TrivialArtifact = new(stubArtifact)
return a
}