listOf :: Parser a -> Parser [a]
listOf p = bracketed (sepBy p (spaces *> char ',' <* spaces)) where
  bracketed = between (char '[' *> spaces) (spaces <* char ']')
listOf :: Parser a -> Parser [a]
listOf p = bracketed (sepBy p (spaces *> char ',' <* spaces)) where
  bracketed = between (char '[' *> spaces) (spaces <* char ']')
listOf p = bracketed (sepBy p (spaces *> char ',' <* spaces)) where
  bracketed = between (char '[' *> spaces) (spaces <* char ']')