emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Seth Lee <lee.seth@protonmail.com>
To: "emacs-orgmode@gnu.org" <emacs-orgmode@gnu.org>
Subject: [PATCH] Update ob-haskell from deprecated inf-haskell-mode to haskell-interactive-mode
Date: Mon, 13 Jul 2020 17:05:06 +0000	[thread overview]
Message-ID: <onq-fWMuc9bRaF1bHpnyIWVmktxe6h3ZNWws91JFxcjHrfaieKssqSrTrJaZVhdCQqH03Vt1TYPBBpFad540MaPZKUlDZQY3TTONqsP911Q=@protonmail.com> (raw)

[-- 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)

             reply	other threads:[~2020-07-14 21:56 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-13 17:05 Seth Lee [this message]
2020-07-27  1:29 ` [PATCH] Update ob-haskell from deprecated inf-haskell-mode to haskell-interactive-mode Kyle Meyer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='onq-fWMuc9bRaF1bHpnyIWVmktxe6h3ZNWws91JFxcjHrfaieKssqSrTrJaZVhdCQqH03Vt1TYPBBpFad540MaPZKUlDZQY3TTONqsP911Q=@protonmail.com' \
    --to=lee.seth@protonmail.com \
    --cc=emacs-orgmode@gnu.org \


* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).