2018-07-14 21:43:12 +02:00
|
|
|
;;; lang/haskell/autoload.el -*- lexical-binding: t; -*-
|
|
|
|
|
|
|
|
;;;###autoload
|
2019-02-18 01:56:38 -05:00
|
|
|
(defun +haskell/open-repl (&optional arg)
|
2018-07-14 21:43:12 +02:00
|
|
|
"Opens a Haskell REPL."
|
|
|
|
(interactive "P")
|
2019-04-02 18:21:34 -04:00
|
|
|
(if-let*
|
|
|
|
((window
|
|
|
|
(display-buffer
|
|
|
|
(if (featurep! +intero)
|
|
|
|
(intero-repl-buffer arg)
|
|
|
|
(haskell-session-interactive-buffer (haskell-session))))))
|
|
|
|
(window-buffer window)
|
|
|
|
(error "Failed to display Haskell REPL")))
|