X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/d8e9122115b5ffcec342c841b81cb2d2b8217e4b..3dd82d7501a28c1ac6cebb9a2fc14399413b5c40:/lisp/emacs-lisp/derived.el diff --git a/lisp/emacs-lisp/derived.el b/lisp/emacs-lisp/derived.el index 52da4c99ea..f30271e15f 100644 --- a/lisp/emacs-lisp/derived.el +++ b/lisp/emacs-lisp/derived.el @@ -1,7 +1,7 @@ ;;; derived.el --- allow inheritance of major modes ;; (formerly mode-clone.el) -;; Copyright (C) 1993-1994, 1999, 2001-2015 Free Software Foundation, +;; Copyright (C) 1993-1994, 1999, 2001-2016 Free Software Foundation, ;; Inc. ;; Author: David Megginson (dmeggins@aix1.uottawa.ca) @@ -331,8 +331,11 @@ which more-or-less shadow%s %s's corresponding table%s." "\n\nThis mode " (concat "\n\nIn addition to any hooks its parent mode " - (if (string-match (regexp-quote (format "`%s'" parent)) - docstring) nil + (if (string-match (format "[`‘]%s['’]" + (regexp-quote + (symbol-name parent))) + docstring) + nil (format "`%s' " parent)) "might have run,\nthis mode ")) (format "runs the hook `%s'" hook)