packages feed

tilia-0.2.0.0: corpora/vendored/cpp/comment/comment-above-a-leading-separator-opening-a-branch-out'.hs

{-# LANGUAGE CPP #-}

module Kiln
    ( Kiln (..)
#if defined(GAS)
      -- the burner is only there with gas
    , burner
#endif
    , firings
    )
where

data Kiln = Kiln
    { chamber :: Int
#if defined(GAS)
      -- litres per hour at full flame
    , flow :: Int
#endif
    }

firings :: [String]
firings =
    [ "bisque"
    , "glaze"
#if defined(GAS)
      -- reduction needs a flame
      -- that can be starved of air
    , "reduction"
#endif
    ]

burner :: Kiln -> IO ()
burner kiln = do
    { print (chamber kiln)
#if defined(GAS)
      -- the flow is only known with gas
    ; print (flow kiln)
#endif
    }