From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0 ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms11 with LMTPS id mHGGONxczF7QfgAA0tVLHw (envelope-from ) for ; Tue, 26 May 2020 00:03:40 +0000 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0 with LMTPS id WD1jNNxczF47DQAA1q6Kng (envelope-from ) for ; Tue, 26 May 2020 00:03:40 +0000 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 0BCAD9404D0 for ; Tue, 26 May 2020 00:03:39 +0000 (UTC) Received: from localhost ([::1]:49590 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jdN4E-0000FY-P1 for larch@yhetil.org; Mon, 25 May 2020 20:03:38 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:50370) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jdN3Y-0000Dm-Pg for emacs-orgmode@gnu.org; Mon, 25 May 2020 20:02:56 -0400 Received: from pb-smtp2.pobox.com ([64.147.108.71]:63446) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1jdN3X-00034i-4t for emacs-orgmode@gnu.org; Mon, 25 May 2020 20:02:56 -0400 Received: from pb-smtp2.pobox.com (unknown [127.0.0.1]) by pb-smtp2.pobox.com (Postfix) with ESMTP id 10D90688F1; Mon, 25 May 2020 20:02:53 -0400 (EDT) (envelope-from kyle@kyleam.com) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=pobox.com; h=from:to:cc :subject:in-reply-to:date:message-id:mime-version:content-type :content-transfer-encoding; s=sasl; bh=8NP5fKyPqJ48sqm85N6UE8NK3 j8=; b=i2GHYa0Xv3yr8je9vu/gLHMTqHZAoVPSbsc7ThXV8hzo4aIZHCx9irUEf 0hOw6kDK1zX/7NDmjKvU3HTwGB1t+K/p7JrmaQW7OviD+K6QDkVrxKplCk3caFKU XNxXo/dppeYyIMX+Rvpg773sAUwuNrUBU+RGJYRiPSmf0HUcaI= Received: from pb-smtp2.nyi.icgroup.com (unknown [127.0.0.1]) by pb-smtp2.pobox.com (Postfix) with ESMTP id 081A4688F0; Mon, 25 May 2020 20:02:53 -0400 (EDT) (envelope-from kyle@kyleam.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed; d=kyleam.com; h=from:to:cc:subject:in-reply-to:date:message-id:mime-version:content-type:content-transfer-encoding; s=mesmtp; bh=MWg6t+QSG07MPnZ8lHw0qM2y4WOD4hXw4vM3+kn+cAA=; b=PBBQHDXCkAf2SNUjXpChRk4pHha+8wA1y7tOrkn8hTVJXsU2jcjAyaUNARblEmGghHsX2yxj72Xv5/RjCSfT3CXfUOXtqJ+eE2TzlcMEzE/sEKuG2WaD+AzhfGfD8/caIEoedH/mfQ5Tss824Z7KIAh1zes6P/R+x9AdkRIs66Q= Received: from localhost (unknown [45.33.91.115]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by pb-smtp2.pobox.com (Postfix) with ESMTPSA id 7E4EF688EF; Mon, 25 May 2020 20:02:52 -0400 (EDT) (envelope-from kyle@kyleam.com) From: Kyle Meyer To: Nick Daly Subject: Re: [PATCH] ob-haskell: Line Continuations Mangle Block Output In-Reply-To: Date: Tue, 26 May 2020 00:02:51 +0000 Message-ID: <874ks3lg0k.fsf@kyleam.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Pobox-Relay-ID: 3E6E193E-9EE4-11EA-A2E1-D1361DBA3BAF-24757444!pb-smtp2.pobox.com Received-SPF: pass client-ip=64.147.108.71; envelope-from=kyle@kyleam.com; helo=pb-smtp2.pobox.com X-detected-operating-system: by eggs.gnu.org: First seen = 2020/05/25 20:02:53 X-ACL-Warn: Detected OS = Linux 2.2.x-3.x [generic] [fuzzy] X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_LOW=-0.7, SPF_PASS=-0.001, URIBL_BLOCKED=0.001 autolearn=_AUTOLEARN X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Doro Rose , Org Mode Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: "Emacs-orgmode" X-Scanner: scn0 Authentication-Results: aspmx1.migadu.com; dkim=fail (rsa verify failed) header.d=pobox.com header.s=sasl header.b=i2GHYa0X; dkim=fail (rsa verify failed) header.d=kyleam.com header.s=mesmtp header.b=PBBQHDXC; dmarc=none; spf=pass (aspmx1.migadu.com: domain of emacs-orgmode-bounces@gnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom=emacs-orgmode-bounces@gnu.org X-Spam-Score: -0.01 X-TUID: latXYJkSk6uK Nick Daly writes: > After a bit of tinkering, I realized there are two things going on > here, only one of which I fully understand: > > 1. My core functional issue is that =3Dcomint-prompt-regexp=3D isn't set > up to handle the "Prelude| " entries or the repeated prompts. The > other patches I submitted were unnecessary. > > 2. The =3Dcomint-prompt-regexp=3D gets default values from somewhere I > don't understand and can't find with a quick source grep. Here's what I can gather. inf-haskell used to set comint-prompt-regexp in the body of inferior-haskell-mode. Here's an example from 11d6abf (2017-08-24): (setq-local comint-prompt-regexp ;; Why the backslash in [\\._[:alnum:]]? "^\\*?[[:upper:]][\\._[:alnum:]]*\\(?: \\*?[[:upper:]][\\._= [:alnum:]]*\\)*\\( =CE=BB\\)?> \\|^=CE=BB?> $") In ca94d81 (revamped inf-haskell, 2017-08-26), which was included in the v17.1 release, haskell-prompt-regexp was introduced and the line above is now (setq-local comint-prompt-regexp haskell-prompt-regexp) > In ob-haskell, we set =3Dcomint-prompt-regexp=3D to the (undefined) > haskell-prompt plus "or optional-lambda": With a haskell-mode after the commit I point to above, it shouldn't be undefined at the time we set comint-prompt-regexp because org-babel-interpret-haskell loads inf-haskell before that. However, I'm confused why Org's b46787743 (Fix ob-haskell.el to work with custom ghci prompts, 2017-12-02) added the =CE=BB bit (author of that patch cc'd). As far as I can tell, that is a part of inferior-haskell-mode's default comint-prompt-regexp and has been since 28997b2 (Add support for popular "=CE=BB> " prompt to inf-haskell, 2013-07-04). You've sent an updated patch in a follow-up message, so I'll continue there...