-O in 6.8.1-candidate

Serge D. Mechveliani mechvel at botik.ru
Thu Oct 18 03:02:49 EDT 2007


On Oct 17, 2007, Don Stewart and Duncan Coutts wrote: 

> > [..]
> > By default cabal uses ghc -O to build projects, so you won't see any
> > difference if you comment it out of the cabal file. You will however
> > if you explicitly turn off optimisations:
> > 
> >     ghc-options: -Onot
> 
> or:
> 
> cabal-setup configure --disable-optimization
> 
> since the default is --enable-optimization which with ghc uses -O


For GHC, it is necessary for the  .cabal  file to provide the field
`ghc-options:',
and the optimization keys are of this field.
Hence, is not this confusing to allow the optimization keys anywhere 
else?
Also seeing `--enable-optimization' the user needs also to recall of what 
kind of optimization is it.

Regards,

-----------------
Serge Mechveliani
mechvel at botik.ru


More information about the Glasgow-haskell-bugs mailing list