[GHC] #10077: Providing type checker plugin on command line results in false cyclic import error

GHC ghc-devs at haskell.org
Fri Apr 24 09:13:38 UTC 2015


#10077: Providing type checker plugin on command line results in false cyclic
import error
-------------------------------------+-------------------------------------
        Reporter:  jbracker          |                   Owner:
            Type:  bug               |                  Status:  new
        Priority:  normal            |               Milestone:
       Component:  Compiler (Type    |                 Version:  7.11
  checker)                           |                Keywords:
      Resolution:                    |  typechecker plugin cycle imports
Operating System:  Linux             |            Architecture:  x86_64
 Type of failure:  Incorrect         |  (amd64)
  warning at compile-time            |               Test Case:
      Blocked By:                    |                Blocking:
 Related Tickets:                    |  Differential Revisions:
-------------------------------------+-------------------------------------

Comment (by adamgundry):

 Replying to [comment:7 ezyang]:
 > Isn't the case here that, when GHC attempts to compile a plugin, it
 shouldn't use the `-fplugin` arguments for the compilation? Simple stage
 restriction: you can't use a plugin on itself.

 That's true, but I'm not quite sure what you're suggesting: do you mean
 that GHC should silently ignore the `-fplugin` argument when compiling the
 plugin itself (and its dependencies)? I guess that would be more
 convenient in this case, although I imagine it would be counterintuitive
 in other cases (e.g. if you were trying to use a plugin on a module
 without realising the plugin depended on that module). Perhaps those other
 cases are sufficiently obscure that it is worth doing, and could perhaps
 be combined with turning on `-dynamic` automatically.

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10077#comment:8>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list