indented :: MonadState PrintState m => m a -> m a
indented m = do
  before <- get
  put PrintState {indent = indent before + 2, hereDoc = hereDoc before}
  x <- m
  after <- get
  put PrintState {indent = indent before, hereDoc = hereDoc after}
  return x
-- TODO: Consider using Lens.

-- | Class of printable syntax.
indented :: MonadState PrintState m => m a -> m a
indented m = do
  before <- get
  put PrintState {indent = indent before + 2, hereDoc = hereDoc before}
  x <- m
  after <- get
  put PrintState {indent = indent before, hereDoc = hereDoc after}
  return x
-- TODO: Consider using Lens.

-- | Class of printable syntax.
indented m = do
  before <- get
  put PrintState {indent = indent before + 2, hereDoc = hereDoc before}
  x <- m
  after <- get
  put PrintState {indent = indent before, hereDoc = hereDoc after}
  return x
-- TODO: Consider using Lens.

-- | Class of printable syntax.