| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Loopbreaker
Description
To use plugin, you can:
- Either enable the plugin globally in your project configuration's
ghc-optionsfield (package.yamlor<name>.cabal):
# package.yaml ... ghc-options: - -fplugin=Loopbreaker ...
- Or alternatively, just enable the plugin in specific modules that may benefit from it's use:
-- <name>.hs
{-# OPTIONS_GHC -fplugin=Loopbreaker #-}
...
If you decide to enable it globally, you can selectively disable it in
specific modules using disable option:
{-# OPTIONS_GHC -fplugin-opt=Loopbreaker:disable #-}
...
Now, in modules where the plugin is enabled, any self-recursive functions
marked as INLINE may have their performance greatly improved.