-- a helper for pretty-printing statement.  'fsep' chooses whether to put the
-- statement on the same line as 'x', or nest it on the next line if it doesn't
-- fit on the same line.
nestStmt :: Doc -> Doc -> Doc
nestStmt x stmt
  = fsep [x, nest 2 stmt ]
nestStmt :: Doc -> Doc -> Doc
nestStmt x stmt
  = fsep [x, nest 2 stmt ]
nestStmt x stmt
  = fsep [x, nest 2 stmt ]