Subject: bug#8840: closed (Re: bug#8840: 24.0.50; python-mode derives from fundamental, not prog-mode)

From: [email-masked] (GNU bug Tracking System)
Date: Wed, 15 Jun 2011 16:19:02 +0000

Your bug report

#8840: 24.0.50; python-mode derives from fundamental, not prog-mode

which was filed against the emacs package, has been closed.

The explanation is attached below, along with your original report.
If you require more details, please reply to [email-masked].

-- 
8840: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=8840
GNU Bug Tracking System
Contact [email-masked] with problems

Subject: Re: bug#8840: 24.0.50; python-mode derives from fundamental, not prog-mode
From: Glenn Morris <[email-masked]>
To: [email-masked]
Date: Wed, 15 Jun 2011 12:18:11 -0400
List-Id: <debbugs-submit.debbugs.gnu.org>

Version: 24.1

It derives from prog-mode now.

Subject: 24.0.50; python-mode derives from fundamental, not prog-mode
From: Michael Moorman <[email-masked]>
To: [email-masked]
Date: Sat, 11 Jun 2011 21:20:55 -0400
List-Id: <debbugs-submit.debbugs.gnu.org>

python-mode in python.el derives from fundamental-mode and not
prog-mode, unlike most other coding modes (e.g. perl-mode), and run
prog-mode-hook as other modes do, which is inconsistent. 

Here's a patch (simple enough!):

=== modified file 'lisp/progmodes/python.el'
*** lisp/progmodes/python.el 2011-05-24 03:38:35 +0000
--- lisp/progmodes/python.el 2011-06-12 00:24:49 +0000
*************** without confirmation."
*** 2420,2426 ****
  (defvar python-mode-running)            ;Dynamically scoped var.
  
  ;;;###autoload
! (define-derived-mode python-mode fundamental-mode "Python"
    "Major mode for editing Python files.
  Turns on Font Lock mode unconditionally since it is currently required
  for correct parsing of the source.
--- 2420,2426 ----
  (defvar python-mode-running)            ;Dynamically scoped var.
  
  ;;;###autoload
! (define-derived-mode python-mode prog-mode "Python"
    "Major mode for editing Python files.
  Turns on Font Lock mode unconditionally since it is currently required
  for correct parsing of the source.

Michael Moorman
https://launchpad.net/~tensorpuddin