From unknown Tue Jun 24 01:38:18 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#17033 <17033@debbugs.gnu.org> To: bug#17033 <17033@debbugs.gnu.org> Subject: Status: 24.3.50; regression in haskell-mode caused by emacs commit 116129 Reply-To: bug#17033 <17033@debbugs.gnu.org> Date: Tue, 24 Jun 2025 08:38:18 +0000 retitle 17033 24.3.50; regression in haskell-mode caused by emacs commit 11= 6129 reassign 17033 emacs submitter 17033 Ian Kelling severity 17033 important tag 17033 notabug thanks From debbugs-submit-bounces@debbugs.gnu.org Tue Mar 18 08:45:10 2014 Received: (at submit) by debbugs.gnu.org; 18 Mar 2014 12:45:10 +0000 Received: from localhost ([127.0.0.1]:39617 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WPtOG-0006kX-9b for submit@debbugs.gnu.org; Tue, 18 Mar 2014 08:45:10 -0400 Received: from eggs.gnu.org ([208.118.235.92]:47933) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WPtO9-0006jj-1G for submit@debbugs.gnu.org; Tue, 18 Mar 2014 08:45:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WPtO1-00005j-Fa for submit@debbugs.gnu.org; Tue, 18 Mar 2014 08:45:00 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,T_DKIM_INVALID autolearn=disabled version=3.3.2 Received: from lists.gnu.org ([2001:4830:134:3::11]:38262) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPtO1-00005Z-Bv for submit@debbugs.gnu.org; Tue, 18 Mar 2014 08:44:53 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:49592) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPtNu-00084Y-V1 for bug-gnu-emacs@gnu.org; Tue, 18 Mar 2014 08:44:53 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WPtNo-0008Vb-II for bug-gnu-emacs@gnu.org; Tue, 18 Mar 2014 08:44:46 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:57949) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WPtNo-0008VM-E0 for bug-gnu-emacs@gnu.org; Tue, 18 Mar 2014 08:44:40 -0400 Received: from compute4.internal (compute4.nyi.mail.srv.osa [10.202.2.44]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id C961A20DC6 for ; Tue, 18 Mar 2014 08:44:38 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute4.internal (MEProxy); Tue, 18 Mar 2014 08:44:38 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=message-id:date:from:mime-version:to :subject:content-type; s=smtpout; bh=0vMInbLL4wx0vwtmGL+SUUZpUc0 =; b=S8ANzoUlvri5m2Ko0kiojpqnnIb4pbDpX0QSw4jwD34W8UfZQvyYr7yskvM 896r7kcs8576IFKx7ru+xA3HVyJ4iGt8S7fRq/qMEg66CVowvzlCrnoRR6iPbadI Y6o88wPmeGi791MKaXslUyAqSW8yV1gf/uzsu1+BaoGflfzg= X-Sasl-enc: 0LoCZ/gCLVMJ1xauNvUx/uEoeDcVxCzpXuCuSBdGRSx/ 1395146678 Received: from [192.168.1.2] (unknown [67.160.118.141]) by mail.messagingengine.com (Postfix) with ESMTPA id 778F96800A4 for ; Tue, 18 Mar 2014 08:44:38 -0400 (EDT) Message-ID: <53283F94.5090607@iankelling.org> Date: Tue, 18 Mar 2014 05:44:04 -0700 From: Ian Kelling User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20131103 Icedove/17.0.10 MIME-Version: 1.0 To: bug-gnu-emacs@gnu.org Subject: 24.3.50; regression in haskell-mode caused by emacs commit 116129 X-Enigmail-Version: 1.5.1 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="----enig2DFARLLPGCEGSQIVJBLFM" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2001:4830:134:3::11 X-Spam-Score: -5.0 (-----) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -5.0 (-----) This is an OpenPGP/MIME signed message (RFC 4880 and 3156) ------enig2DFARLLPGCEGSQIVJBLFM Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable The bug causes an error on execution of haskell-interactive-switch, and o= ther haskell-interactive commands, leaving haskell-interactive-mode totally br= oken. The backtrace I have is a bit confusing because the code listed is a resu= lt of macro expansion, but here is an explanation of what appears to be happeni= ng. This line from haskell-mode's haskell-process.el is executed (check-type cmd haskell-command) which macro expands to become (haskell-command cmd) but haskell-command is a defstruct, leading to void-function error. The expansion problem is from cl--make-type-test, specifically last line = of code added from the bzr 116129 commit. If not that line, I have tested for sur= e that the problem was introduced by that commit. It manifests only when haskell-mode is not compiled, or haskell-mode's el= isp files are each compiled with separate emacs commands. Excerpt from that commit including its last line: - (if (fboundp namep) (list namep val) - (list (intern (concat name "-p")) val))))) + (cond + ((cl--macroexp-fboundp namep) (list namep val)) + ((cl--macroexp-fboundp + (setq namep (intern (concat name "-p")))) + (list namep val)) + (t (list type val)))))) haskell-mode is not part of emacs, but I wasn't able to easily reproduce = it with test code. I tested this with emacs -Q, and then loading a recent version= of haskell-mode. Here is a backtrace output: Debugger entered--Lisp error: (void-function haskell-command) (haskell-command cmd) (or (haskell-command cmd) (signal (quote wrong-type-argument) (list (qu= ote haskell-command) cmd (quote cmd)))) (progn (or (haskell-command cmd) (signal (quote wrong-type-argument) (l= ist (quote haskell-command) cmd (quote cmd)))) nil) haskell-process-cmd-queue-add(((name . "tmphaskproj") (inferior-process= . #) (is-restarting) (current-command) (session (name = =2E "tmphaskproj") (current-dir . "/tmp/") (cabal-checksum) (cabal-dir . "/tm= p/") (process (name . "tmphaskproj") (inferior-process . #) (is-restarting) (current-command) #1))) [cl-struct-haskell-command ((name= . "tmphaskproj") (inferior-process . #) (is-restarting= ) (current-command) (session (name . "tmphaskproj") (current-dir . "/tmp/")= (cabal-checksum) (cabal-dir . "/tmp/") (process (name . "tmphaskproj") (inferior-process . #) (is-restarting) (current-comm= and) #2))) (lambda (process) (haskell-process-send-string process ":set prompt= \"> \"") (haskell-process-send-string process "Prelude.putStrLn \"\"") (haskell-process-send-string process ":set -v1")) (lambda (process buffer= ) (if (haskell-process-consume process "^*** WARNING: \\(.+\\) is writable by s= omeone else, IGNORING!$") (progn (let ((path (match-string 1 buffer))) (haskell-session-modify (haskell-process-session process) (quote ignored-= files) (function (lambda ... ...))) (haskell-interactive-mode-compile-warning (haskell-process-session process) (format "GHCi is ignoring: %s (run M-x haskell-process-unignore)" path)))))) (lambda (process _) (haskell-interactive-mode-echo (haskell-process-session process) (concat = (nth (random (length haskell-process-greetings)) haskell-process-greetings) (i= f haskell-process-show-debug-tips (progn "\nIf I break, you can:\n 1. Rest= art: M-x haskell-process-restart\n 2. Configure logging: C-h v haskell-process-log (useful for debugging)\n 3. General config: M-x customize-mode\n 4. Hide these tips: C-h v haskell-process-show-debug-= tips")))))]) haskell-process-queue-command(((name . "tmphaskproj") (inferior-process= . #) (is-restarting) (current-command) (session (name = =2E "tmphaskproj") (current-dir . "/tmp/") (cabal-checksum) (cabal-dir . "/tm= p/") (process (name . "tmphaskproj") (inferior-process . #) (is-restarting) (current-command) #1))) [cl-struct-haskell-command ((name= . "tmphaskproj") (inferior-process . #) (is-restarting= ) (current-command) (session (name . "tmphaskproj") (current-dir . "/tmp/")= (cabal-checksum) (cabal-dir . "/tmp/") (process (name . "tmphaskproj") (inferior-process . #) (is-restarting) (current-comm= and) #2))) (lambda (process) (haskell-process-send-string process ":set prompt= \"> \"") (haskell-process-send-string process "Prelude.putStrLn \"\"") (haskell-process-send-string process ":set -v1")) (lambda (process buffer= ) (if (haskell-process-consume process "^*** WARNING: \\(.+\\) is writable by s= omeone else, IGNORING!$") (progn (let ((path (match-string 1 buffer))) (haskell-session-modify (haskell-process-session process) (quote ignored-= files) (function (lambda ... ...))) (haskell-interactive-mode-compile-warning (haskell-process-session process) (format "GHCi is ignoring: %s (run M-x haskell-process-unignore)" path)))))) (lambda (process _) (haskell-interactive-mode-echo (haskell-process-session process) (concat = (nth (random (length haskell-process-greetings)) haskell-process-greetings) (i= f haskell-process-show-debug-tips (progn "\nIf I break, you can:\n 1. Rest= art: M-x haskell-process-restart\n 2. Configure logging: C-h v haskell-process-log (useful for debugging)\n 3. General config: M-x customize-mode\n 4. Hide these tips: C-h v haskell-process-show-debug-= tips")))))]) haskell-process-send-startup(((name . "tmphaskproj") (inferior-process = =2E #) (is-restarting) (current-command) (session (name = =2E "tmphaskproj") (current-dir . "/tmp/") (cabal-checksum) (cabal-dir . "/tm= p/") (process (name . "tmphaskproj") (inferior-process . #) (is-restarting) (current-command) #1)))) (let ((process (or (haskell-session-process session) (haskell-process-m= ake (haskell-session-name session)))) (old-queue (haskell-process-get (haskell-session-process session) (quote command-queue)))) (haskell-session-set-process session process) (haskell-process-set-sessio= n process session) (haskell-process-set-cmd process nil) (haskell-process-set (haskell-session-process session) (quote is-restarting) nil) (let ((default-directory (haskell-session-cabal-dir session))) (haskell-sessio= n-pwd session) (haskell-process-set-process process (cond ((memql haskell-proce= ss-type (quote (quote ghci))) (haskell-process-log (format "Starting inferior GHC= i process %s ..." haskell-process-path-ghci)) (apply (function start-process) (appe= nd (list =2E.. nil haskell-process-path-ghci) haskell-process-args-ghci))) ((memql= haskell-process-type (quote (quote cabal-repl))) (haskell-process-log (fo= rmat "Starting inferior `cabal repl' process using %s ..." haskell-process-pat= h-cabal)) (apply (function start-process) (append (list ... nil haskell-process-pat= h-cabal) (quote ...) haskell-process-args-cabal-repl (let ... ...)))) ((memql haskell-process-type (quote (quote cabal-ghci))) (haskell-process-log (fo= rmat "Starting inferior cabal-ghci process using %s ..." haskell-process-path-cabal-ghci)) (start-process (haskell-session-name se= ssion) nil haskell-process-path-cabal-ghci)) ((memql haskell-process-type (quote= (quote cabal-dev))) (let ((dir ...)) (haskell-process-log (format "Starting infe= rior cabal-dev process %s -s %s ..." haskell-process-path-cabal-dev dir)) (start-process (haskell-session-name session) nil haskell-process-path-ca= bal-dev "ghci" "-s" dir))) ((error "cl-ecase failed: %s, %s" haskell-process-type= (quote (ghci quote cabal-repl quote cabal-ghci quote cabal-dev quote))) nil)))) = (progn (set-process-sentinel (haskell-process-process process) (quote haskell-process-sentinel)) (set-process-filter (haskell-process-process p= rocess) (quote haskell-process-filter))) (haskell-process-send-startup process) (= if (eq (quote cabal-repl) haskell-process-type) nil (haskell-process-change-dir = session process (haskell-session-current-dir session))) (haskell-process-set proc= ess (quote command-queue) (append (haskell-process-get (haskell-session-proce= ss session) (quote command-queue)) old-queue)) process) haskell-process-start(((name . "tmphaskproj") (current-dir . "/tmp/") (cabal-checksum) (cabal-dir . "/tmp/") (process (name . "tmphaskproj") (inferior-process . #) (is-restarting) (current-comm= and) (session (name . "tmphaskproj") (current-dir . "/tmp/") (cabal-checksum) (cabal-dir . "/tmp/") #1)))) (let ((session (set (make-local-variable (quote haskell-session)) (list= (cons (quote name) name))))) (add-to-list (quote haskell-sessions) session) (haskell-process-start session) session) haskell-session-make("tmphaskproj") (progn (haskell-session-make name)) (if (not (string=3D name "")) (progn (haskell-session-make name))) (let ((name (read-from-minibuffer "Project name: " (haskell-session-default-name)))) (if (not (string=3D name "")) (progn (haskell-session-make name)))) haskell-session-new() (or (haskell-session-from-buffer) (haskell-session-new-assume-from-caba= l) (haskell-session-choose) (haskell-session-new)) (haskell-session-assign (or (haskell-session-from-buffer) (haskell-session-new-assume-from-cabal) (haskell-session-choose) (haskell-session-new))) (or (haskell-session-maybe) (haskell-session-assign (or (haskell-session-from-buffer) (haskell-session-new-assume-from-cabal) (haskell-session-choose) (haskell-session-new)))) haskell-session() (haskell-session-interactive-buffer (haskell-session)) (let ((buffer (haskell-session-interactive-buffer (haskell-session)))) = (if (eq buffer (window-buffer)) nil (switch-to-buffer-other-window buffer))) haskell-interactive-switch() call-interactively(haskell-interactive-switch record nil) command-execute(haskell-interactive-switch record) execute-extended-command(nil "haskell-interactive-switch") call-interactively(execute-extended-command nil nil) command-execute(execute-extended-command) ------enig2DFARLLPGCEGSQIVJBLFM Content-Type: application/pgp-signature; name="signature.asc" Content-Description: OpenPGP digital signature Content-Disposition: attachment; filename="signature.asc" -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) Comment: Using GnuPG with Icedove - http://www.enigmail.net/ iQIcBAEBCgAGBQJTKD+UAAoJEKrMwkDpacZ7BgcP/1AoIlwWFsih2nZ540x8c6t5 DmnhJUfmgRSbrtZevAO46UunZnO254BVZ+pxIXOf7uaY28AqfOZ1qu35Mm/WaCuT KE8lSTc7cj/llmPPIMPUP7CXN+JbcWF/FTePcvvoZC1+e2gmKhiTwQYhr+W4/ZCR F+HAGj0rupZEGcTeS+Lbv7iH9HeRA7jL4HWfwin13LA3mDilrocXZOA6n/eSOQHE 3CXgNj2IIz1XreU+NdWdLniwE1XIKwQ3pyWy4YPY8YIWs4lmc3aODa4vyiVtXfBU iL438IM4kvRwLCKBmme+ZRNOHmLIyEjV03ZVzFURp1oVUvqnB4n6W4gv80TT3OHg 3h1SFnzwp1gbWdq6V+v9qvsREmOn2TbOKoiRMVhNfimyIFkuMCYw4eQJ8Vh5dalr zy8E1kqKbLrAcAFGXQhCRRTh5ncOv+W823gidVHe+3jT7OWPukYgp3trFl9TNqoM WJKzeaOf2/U6qqCBeoieLSCr+GZkdgwvf4hd+KL5SpI8IGbgQMLJMLdTiIsn+LwU IRsOYYFrZW4T2tRCTI9edBApKGmdG/7ZKnUvRJITR4RDGNkNX2LS+0o9XC9sHmkW ZMm2A8ezp8MxZ3LFtqJDBpeKNsgSbjji/u9siuoNq9m/R8TwONUu3ICOGN0Smpfo 46jx0zVOaFo7ZwCblbR3 =FfYH -----END PGP SIGNATURE----- ------enig2DFARLLPGCEGSQIVJBLFM-- From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 20 12:32:17 2014 Received: (at 17033) by debbugs.gnu.org; 20 Mar 2014 16:32:17 +0000 Received: from localhost ([127.0.0.1]:42510 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQft9-0003wK-Ra for submit@debbugs.gnu.org; Thu, 20 Mar 2014 12:32:16 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.181]:3348) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQft6-0003w9-OS for 17033@debbugs.gnu.org; Thu, 20 Mar 2014 12:32:13 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av8EABK/CFHO+KKg/2dsb2JhbABEuzWDWRdzgh4BAQQBViMFCws0EhQYDSSIHgbBLZEKA44YlmKBXoMT X-IPAS-Result: Av8EABK/CFHO+KKg/2dsb2JhbABEuzWDWRdzgh4BAQQBViMFCws0EhQYDSSIHgbBLZEKA44YlmKBXoMT X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="52774385" Received: from 206-248-162-160.dsl.teksavvy.com (HELO pastel.home) ([206.248.162.160]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 20 Mar 2014 12:32:12 -0400 Received: by pastel.home (Postfix, from userid 20848) id E40FF6012B; Thu, 20 Mar 2014 12:32:11 -0400 (EDT) From: Stefan To: Ian Kelling Subject: Re: bug#17033: 24.3.50; regression in haskell-mode caused by emacs commit 116129 Message-ID: References: <53283F94.5090607@iankelling.org> Date: Thu, 20 Mar 2014 12:32:11 -0400 In-Reply-To: <53283F94.5090607@iankelling.org> (Ian Kelling's message of "Tue, 18 Mar 2014 05:44:04 -0700") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: 17033 Cc: 17033@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.3 (/) > This line from haskell-mode's haskell-process.el is executed > (check-type cmd haskell-command) > which macro expands to become > (haskell-command cmd) > but haskell-command is a defstruct, leading to void-function error. This is an error in haskell-process.el which uses (check-type cmd haskell-command) on line 1268 before defining the haskell-command struct on line 1375. If you hoist the defstruct before the check-type, things should work again. Stefan From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 20 12:33:04 2014 Received: (at control) by debbugs.gnu.org; 20 Mar 2014 16:33:04 +0000 Received: from localhost ([127.0.0.1]:42516 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQftu-0003xx-Tj for submit@debbugs.gnu.org; Thu, 20 Mar 2014 12:33:03 -0400 Received: from ironport2-out.teksavvy.com ([206.248.154.181]:64395) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1WQftq-0003xf-Ma for control@debbugs.gnu.org; Thu, 20 Mar 2014 12:32:59 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AmAFABK/CFHO+KKg/2dsb2JhbABEj0SrcYNZF3OCHwEFVjMLNBIUGA2ISMEtjWGDKQOOGJZigV6DEw X-IPAS-Result: AmAFABK/CFHO+KKg/2dsb2JhbABEj0SrcYNZF3OCHwEFVjMLNBIUGA2ISMEtjWGDKQOOGJZigV6DEw X-IronPort-AV: E=Sophos;i="4.84,565,1355115600"; d="scan'208";a="52774486" Received: from 206-248-162-160.dsl.teksavvy.com (HELO pastel.home) ([206.248.162.160]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 20 Mar 2014 12:32:58 -0400 Received: by pastel.home (Postfix, from userid 20848) id 10B516012B; Thu, 20 Mar 2014 12:32:58 -0400 (EDT) From: Stefan To: control@debbugs.gnu.org Subject: Re: bug#17033: 24.3.50; regression in haskell-mode caused by emacs commit 116129 Message-ID: References: <53283F94.5090607@iankelling.org> Date: Thu, 20 Mar 2014 12:32:58 -0400 In-Reply-To: <53283F94.5090607@iankelling.org> (Ian Kelling's message of "Tue, 18 Mar 2014 05:44:04 -0700") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.3 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.3 (/) tags 17033 notabug close 17033 thanks From unknown Tue Jun 24 01:38:18 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Fri, 18 Apr 2014 11:24:04 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator