]> code.delx.au - gnu-emacs/blobdiff - lisp/progmodes/cperl-mode.el
SQL mode version 2.1
[gnu-emacs] / lisp / progmodes / cperl-mode.el
index 2f751f2a0dc2f3c5f72f04eb2ad2a4e5d9cc77c1..d69cce76faa86f0a6a35785ce62a02d8d89e269d 100644 (file)
@@ -8980,6 +8980,18 @@ do extra unwind via `cperl-unwind-to-safe'."
     (substring v (match-beginning 1) (match-end 1)))
   "Version of IZ-supported CPerl package this file is based on.")
 
+(defun cperl-mode-unload-function ()
+  "Unload the Cperl mode library."
+  (let ((new-mode (if (eq (symbol-function 'perl-mode) 'cperl-mode)
+                     'fundamental-mode
+                   'perl-mode)))
+    (dolist (buf (buffer-list))
+      (with-current-buffer buf
+       (when (eq major-mode 'cperl-mode)
+         (funcall new-mode)))))
+  ;; continue standard unloading
+  nil)
+
 (provide 'cperl-mode)
 
 ;; arch-tag: 42e5b19b-e187-4537-929f-1a7408980ce6