emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* [PATCH] Update ob-haskell from deprecated inf-haskell-mode to haskell-interactive-mode
@ 2020-07-13 17:05 Seth Lee
  2020-07-27  1:29 ` Kyle Meyer
  0 siblings, 1 reply; 2+ messages in thread
From: Seth Lee @ 2020-07-13 17:05 UTC (permalink / raw)
  To: emacs-orgmode@gnu.org

[-- Attachment #1.1: Type: text/plain, Size: 549 bytes --]

Hello, I've made a patch for `ob-haskell.el`.
I'm not really an elisper, but I made a patch that seems to work on my machine.

Issue: compiling code in a source block that had an infinite list that would evaluate in the ghci.
All code, even with `:compile` flag set would be run in ghci.

Updating deprecated `inf-haskell-mode` to `haskell-interactive-mode` solves the issue for me.

Source blocks flagged to compile will compile in a temp file, and those flagged otherwise will be run interactively. This is the intended behaviour.

Patch attached.

[-- Attachment #1.2: Type: text/html, Size: 700 bytes --]

[-- Attachment #2: 0001-ob-haskell.el-Update-deprecated-functions.patch --]
[-- Type: application/octet-stream, Size: 1202 bytes --]

From 3f7eabc693205e6b199d290a0acfdad09976d6d2 Mon Sep 17 00:00:00 2001
From: Seth Lee <lee.seth@protonmail.com>
Date: Mon, 13 Jul 2020 12:46:27 -0400
Subject: [PATCH] ob-haskell.el: Update deprecated functions

* lisp/ob-haskell.el: Update to haskell-interactive-mode from inf-haskell-mode

Deprecated commands from inf-haskell mode would send source blocks
flagged to compile to the interpreter instead of compiling in a temp

 lisp/ob-haskell.el | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lisp/ob-haskell.el b/lisp/ob-haskell.el
index 84e2d6c42..01d658615 100644
--- a/lisp/ob-haskell.el
+++ b/lisp/ob-haskell.el
@@ -43,9 +43,9 @@
 (require 'comint)
 (declare-function haskell-mode "ext:haskell-mode" ())
-(declare-function run-haskell "ext:inf-haskell" (&optional arg))
+(declare-function run-haskell "ext:haskell-interactive-mode" (&optional arg))
 (declare-function inferior-haskell-load-file
-		  "ext:inf-haskell" (&optional reload))
+		  "ext:haskell-process-load-file" (&optional reload))
 (declare-function org-entry-get "org" (pom property &optional inherit literal-nil))
 (defvar org-babel-tangle-lang-exts)
2.24.3 (Apple Git-128)

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-07-27  1:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-13 17:05 [PATCH] Update ob-haskell from deprecated inf-haskell-mode to haskell-interactive-mode Seth Lee
2020-07-27  1:29 ` Kyle Meyer

Code repositories for project(s) associated with this public inbox


This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).