 
            
            
            
            
                25 Mar
                
                    2013
                
            
            
                25 Mar
                
                '13
                
            
            
            
        
    
                1:22 p.m.
            
        On Mon, 25 Mar 2013, Andreas Voellmy wrote:
Yes, If I rename A.hsc to A.hs, it works fine (without the "build-depends: foo" in the cabal file).
Then it may work by accident, since GHC finds the module A in the same directory as B. Am I right that GHC recompiles A when it compiles B? This should not happen, since GHC should only use the modules the are explicitly listed in a section (library or executable). However Cabal calls 'ghc --make' and this fetches modules automatically even if Cabal does not tell it to do so. If library and executable would use different directories (Hs-source-dirs), it might not work, as expected.