-
Duncan Coutts authored
In the corner case that a package has no components then if we allow it to be handled as normal per-component nodes then the whole package would vanish from the plan, which breaks later error reporting. Instead we keep 0-component packages as whole-package nodes (as we do in a few other cases like old Cabal versions or custom Setup scripts). Later on we need to be able to look up package names that users have requested and find what components they contain. It's ok to report that a package has no components, but it's not ok to report that the package does not exist at all. Hence it's important to preserve these packages in the plan. If we ever move fully to a per-component plan then we will need to revisit this issue of how to represent packages with no components.
2da8b18d