[GHC] #7595: Static flags code needs cleanup

GHC cvs-ghc at haskell.org
Wed Jan 16 13:04:05 CET 2013


#7595: Static flags code needs cleanup
-----------------------------+----------------------------------------------
Reporter:  jstolarek         |          Owner:  jstolarek       
    Type:  task              |         Status:  new             
Priority:  normal            |      Component:  Driver          
 Version:  7.7               |       Keywords:                  
      Os:  Unknown/Multiple  |   Architecture:  Unknown/Multiple
 Failure:  None/Unknown      |      Blockedby:                  
Blocking:                    |        Related:                  
-----------------------------+----------------------------------------------
 While reading through the source code I noticed that code responsible for
 handling static flags could use some refactoring:

  * there are two modules that handle static flags:
 [[GhcFile(compiler/main/StaticFlags.hs)]] and
 [[GhcFile(compiler/main/StaticFlagParser.hs)]]. This is about 300 lines of
 code total and can be easily placed within a single file, especially that
 division of functions between these two files is sometimes confusing.
  * [[GhcFile(compiler/main/StaticFlags.hs)]] contains code responsible for
 handling dynamic flags.

 I will merge code from [[GhcFile(compiler/main/StaticFlagParser.hs)]] into
 into [[GhcFile(compiler/main/StaticFlags.hs)]], create a
 [[GhcFile(compiler/main/StaticFlags.hs-boot)]] to break module dependency
 cycles and move the code for handling dynamic flags to
 [[GhcFile(compiler/main/DynFlags.hs)]]

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/7595>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler



More information about the ghc-tickets mailing list