Skip to content
Snippets Groups Projects
Commit 30e44447 authored by Martin Stjernholm's avatar Martin Stjernholm
Browse files

Compatibility fixes for GNU Emacs.

Rev: lib/tools/pike.el:1.2
parent 945fbe81
No related branches found
No related tags found
No related merge requests found
;;; pike.el -- Major mode for editing Pike and other LPC files. ;;; pike.el -- Major mode for editing Pike and other LPC files.
;;; $Id: pike.el,v 1.1 1999/06/26 06:22:22 peter Exp $ ;;; $Id: pike.el,v 1.2 1999/06/27 15:15:42 mast Exp $
;;; Copyright (C) 1995, 1996, 1997, 1998, 1999 Per Hedbor. ;;; Copyright (C) 1995, 1996, 1997, 1998, 1999 Per Hedbor.
;;; This file is distributed as GPL ;;; This file is distributed as GPL
...@@ -24,6 +24,10 @@ ...@@ -24,6 +24,10 @@
(require 'font-lock) (require 'font-lock)
;; Added in later font-lock versions. Copied here for backward
;; compatibility.
(defvar font-lock-preprocessor-face 'font-lock-keyword-face
"Don't even think of using this.")
(defconst pike-font-lock-keywords-1 nil (defconst pike-font-lock-keywords-1 nil
"For consideration as a value of `pike-font-lock-keywords'. "For consideration as a value of `pike-font-lock-keywords'.
...@@ -244,7 +248,7 @@ The name is assumed to begin with a capital letter.") ...@@ -244,7 +248,7 @@ The name is assumed to begin with a capital letter.")
;; These must come first or the Modifiers from keywords-1 will ;; These must come first or the Modifiers from keywords-1 will
;; catch them. We don't want to use override fontification here ;; catch them. We don't want to use override fontification here
;; because then these terms will be fontified within comments. ;; because then these terms will be fontified within comments.
("\\<public\\>" 0 font-lock-reference-face) ("\\<public\\>" 0 font-lock-preprocessor-face)
("\\<inline\\>" 0 font-lock-preprocessor-face) ("\\<inline\\>" 0 font-lock-preprocessor-face)
("\\<final\\>" 0 font-lock-preprocessor-face) ("\\<final\\>" 0 font-lock-preprocessor-face)
("\\<static\\>" 0 font-lock-preprocessor-face) ("\\<static\\>" 0 font-lock-preprocessor-face)
...@@ -295,11 +299,14 @@ The name is assumed to begin with a capital letter.") ...@@ -295,11 +299,14 @@ The name is assumed to begin with a capital letter.")
(error t))))) (error t)))))
(put 'pike-mode 'font-lock-defaults (if (not (assq 'pike-mode font-lock-defaults-alist))
'((pike-font-lock-keywords (setq font-lock-defaults-alist
pike-font-lock-keywords-1 pike-font-lock-keywords-2 (cons
pike-font-lock-keywords-3) (cons 'pike-mode
nil nil ((?_ . "w")) beginning-of-defun '((pike-font-lock-keywords pike-font-lock-keywords-1
(font-lock-mark-block-function . mark-defun))) pike-font-lock-keywords-2 pike-font-lock-keywords-3)
nil nil ((?_ . "w")) beginning-of-defun
(font-lock-mark-block-function . mark-defun)))
font-lock-defaults-alist)))
(autoload 'pike-mode "cc-mode" "Major mode for editing Pike code.") (autoload 'pike-mode "cc-mode" "Major mode for editing Pike code.")
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment