-
Notifications
You must be signed in to change notification settings - Fork 2.7k
Description
Internally Cargo uses =a.b.c dependencies to tell the Dependency Resolver about things that are fixed by a lockfile. lock_to is used to make the synthetic dependencies, and is_exact to guess if it is synthetic. This works pretty well. We only rarely get a real dependency and a synthetic one confused, and it matters basically never. Except that #9827 now can show the dependency to the user. It would be nice if we could say "which satisfies dependency A > "1.0.0" (pinned to 1.2.3 by the lockfile)" instead of "which satisfies dependency A = "1.2.3"".
My proposed solution is to add a variant to OptVersionReq for the synthetic lockfile dependencies. Something like Locked(Version, VersionReq), So that its display can record the original requirement and the version it is pinned to.