From 8a525646b0d1b78ecd3e36bf34f7002625814cf5 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 3 Jan 2005 20:46:22 +0000 Subject: [PATCH] (perl-nochange, perl-calculate-indent): Don't confuse module-prefixed identifiers for labels. Reported by Juan-Leon Lahoz Garcia . --- lisp/ChangeLog | 6 ++++++ lisp/progmodes/perl-mode.el | 8 ++++---- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ac78d4d7f9a..7ad139850ba 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2005-01-03 Stefan Monnier + + * progmodes/perl-mode.el (perl-nochange, perl-calculate-indent): + Don't confuse module-prefixed identifiers for labels. + Reported by Juan-Leon Lahoz Garcia . + 2005-01-02 Richard M. Stallman * files.el (basic-save-buffer-1): Fix previous change. diff --git a/lisp/progmodes/perl-mode.el b/lisp/progmodes/perl-mode.el index c24e8046b66..eb630c2ed54 100644 --- a/lisp/progmodes/perl-mode.el +++ b/lisp/progmodes/perl-mode.el @@ -1,6 +1,6 @@ ;;; perl-mode.el --- Perl code editing commands for GNU Emacs -;; Copyright (C) 1990, 1994, 2003 Free Software Foundation, Inc. +;; Copyright (C) 1990, 1994, 2003, 2005 Free Software Foundation, Inc. ;; Author: William F. Mann ;; Maintainer: FSF @@ -408,7 +408,7 @@ existing comment, moves to end-of-line, or if at end-of-line already, create a new comment." :type 'boolean) -(defcustom perl-nochange ";?#\\|\f\\|\\s(\\|\\(\\w\\|\\s_\\)+:" +(defcustom perl-nochange ";?#\\|\f\\|\\s(\\|\\(\\w\\|\\s_\\)+:[^:]" "*Lines starting with this regular expression are not auto-indented." :type 'regexp) @@ -769,7 +769,7 @@ Optional argument PARSE-START should be the position of `beginning-of-defun'." (skip-chars-forward " \t\f\n") (cond ((looking-at ";?#") (forward-line 1) t) - ((looking-at "\\(\\w\\|\\s_\\)+:") + ((looking-at "\\(\\w\\|\\s_\\)+:[^:]") (save-excursion (end-of-line) (setq colon-line-end (point))) @@ -929,5 +929,5 @@ With argument, repeat that many times; negative args move backward." (provide 'perl-mode) -;;; arch-tag: 8c7ff68d-15f3-46a2-ade2-b7c41f176826 +;; arch-tag: 8c7ff68d-15f3-46a2-ade2-b7c41f176826 ;;; perl-mode.el ends here -- 2.39.2