Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Reusing Build-Depends version ranges from library part for an executable #1705
Since version 1.14 Cabal properly supports importing the library in an executable in the same package, which I use more and more. However, there is still often a large overlap of packages listed in the Build-Depends. It's tedious and error-prone to manage the version bounds in the Build-Depends of all package parts. That's why I tend to omit the version ranges for the packages imported to the executables. I hope that then Cabal chooses the same version for the library and the executable. However, it might be that I remove a package dependency and its version range from the library part, and thus leave a package dependency without version range in the executable.
My question is: Would it be reasonable to allow a special kind of version range like "same as for the library" that I can use in an executable part? If the according package is not imported to the library then Cabal should abort with an error message.
Somehow related to #938.