GNU bug report logs - #46003
prolog-mode: inferior prolog process not available when prolog-inferior-mode-hook is run

Previous Next

Package: emacs;

Reported by: Tim Lee <progscriptclone <at> gmail.com>

Date: Wed, 20 Jan 2021 08:34:01 UTC

Severity: normal

Fixed in version 29.1

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #8 received at 46003 <at> debbugs.gnu.org (full text, mbox):

From: k3tu0isui <at> gmail.com
To: progscriptclone <at> gmail.com
Cc: 46003 <at> debbugs.gnu.org
Subject: #46003: should this be a bug?
Date: Wed, 27 Jan 2021 11:41:34 +0530
Is it a requirement for a buffer in a inferior-mode to always have a
process? 
When you call run-prolog or prolog-consult-buffer, if a prolog process
is not running, a *prolog* buffer is created, prolog-inferior-mode is
activated in the buffer and THEN the process itself is run. Relevant code
from prolog-ensure-process function.

      (with-current-buffer (get-buffer-create "*prolog*")
	(prolog-inferior-mode)
...
          (apply 'make-comint-in-buffer "prolog" (current-buffer)
	         (prolog-program-name) nil (prolog-program-switches)))

I assume this was required because (prolog-inferior-mode) sets up the
variables required for (prolog-program-name) and (prolog-program-switches).

If the relevant variables are inherited from the buffer from which run-prolog is
called then, this bug fix[1] will remove this dependency and prolog-inferior-mode
can be activated after the process is created.

[1]: https://debbugs.gnu.org/cgi/bugreport.cgi?bug=45795




This bug report was last modified 3 years and 68 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.