Function: haskell-cabal-with-subsection-line

haskell-cabal-with-subsection-line is a macro defined in haskell-cabal.el.

Signature

(haskell-cabal-with-subsection-line REPLACE &rest FORMS)

Documentation

Mark line, copy subsection data into a temporary buffer, save indentation and execute FORMS at the marked line.

If REPLACE is non-nil the subsection data is replaced with the resulting buffer-content. Unmark line at the end.

Source Code

;; Defined in /nix/store/9lz2mhw95f9fqxr9mnq46k3f6qz3aq83-emacs-packages-deps/share/emacs/site-lisp/elpa/haskell-mode-20260904.1042/haskell-cabal.el
(defmacro haskell-cabal-with-subsection-line (replace &rest forms)
  "Mark line, copy subsection data into a temporary buffer, save indentation
and execute FORMS at the marked line.

If REPLACE is non-nil the subsection data is replaced with the
resulting buffer-content.  Unmark line at the end."
  `(progn
     (haskell-cabal-mark)
     (unwind-protect
         (haskell-cabal-with-subsection (haskell-cabal-subsection) ,replace
          (haskell-cabal-goto-mark)
          ,@forms)
       (haskell-cabal-remove-mark))))