[GHC] #9846: GHC --make should also look for .hi, not only for .hs

#9846: GHC --make should also look for .hi, not only for .hs -------------------------------------+------------------------------------- Reporter: larsrh | Owner: Type: feature request | Status: new Priority: normal | Milestone: ⊥ Component: Compiler | Version: Keywords: | Operating System: Architecture: Unknown/Multiple | Unknown/Multiple Difficulty: Unknown | Type of failure: Blocked By: | None/Unknown Related Tickets: | Test Case: | Blocking: | Differential Revisions: -------------------------------------+------------------------------------- Currently, `ghc --make` will only consider .hs source files from the include path. Example (assuming `Library` can't be resolved from the package database): `A.hs` {{{#!hs module A where import B import Library }}} `B.hs` {{{#!hs module B where }}} Compiling these files with `ghc --make -Idir A.hs B.hs` will succeed only if GHC finds a `Library.hs` file. In a thread on [https://www.haskell.org/pipermail/glasgow-haskell- users/2014-November/025476.html glasgow-haskell-users], Simon proposed relaxing this constraint; namely: In `--make` mode, when encountering an import `X`, GHC will try the following in order: 1. resolve the import from a package 2. search the include path for `X.hs` or `X.lhs` 3. search the include path for `X.hi` It already does 1 and 2, and this proposal would add 3. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9846 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9846: GHC --make should also look for .hi, not only for .hs -------------------------------------+------------------------------------- Reporter: larsrh | Owner: Type: feature | Status: new request | Milestone: ⊥ Priority: normal | Version: Component: Compiler | Keywords: Resolution: | Architecture: Unknown/Multiple Operating System: | Difficulty: Unknown Unknown/Multiple | Blocked By: Type of failure: | Related Tickets: None/Unknown | Test Case: | Blocking: | Differential Revisions: | -------------------------------------+------------------------------------- Changes (by rodlogic): * cc: rodlogic (added) -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9846#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#9846: GHC --make should also look for .hi, not only for .hs -------------------------------------+------------------------------------- Reporter: larsrh | Owner: Type: feature request | Status: new Priority: normal | Milestone: Component: Driver | Version: Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: None/Unknown | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Changes (by thomie): * component: Compiler => Driver * milestone: ⊥ => -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/9846#comment:2 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC