changeset 57719:018ef6100fc5

(cc-other-file-alist): Bring it in line with cc-mode's auto-mode-alist entries and use \' instead of $.
author Daniel Pfeiffer <occitan@esperanto.org>
date Tue, 26 Oct 2004 21:39:34 +0000
parents e60d53125cf2
children 557213a7ca17
files lisp/find-file.el
diffstat 1 files changed, 17 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/find-file.el	Tue Oct 26 21:38:57 2004 +0000
+++ b/lisp/find-file.el	Tue Oct 26 21:39:34 2004 +0000
@@ -57,7 +57,7 @@
 ;; format above can be changed to include a function to be called when the
 ;; current file matches the regexp:
 ;;
-;;   '(("\\.cc$"  cc-function)
+;;   '(("\\.cc$"  cc--function)
 ;;     ("\\.hh$"  hh-function))
 ;;
 ;; These functions must return a list consisting of the possible names of the
@@ -239,22 +239,26 @@
   :group 'ff)
 
 (defcustom cc-other-file-alist
-  '(
-    ("\\.cc$"  (".hh" ".h"))
-    ("\\.hh$"  (".cc" ".C"))
+  '(("\\.cc\\'"  (".hh" ".h"))
+    ("\\.hh\\'"  (".cc" ".C"))
 
-    ("\\.c$"   (".h"))
-    ("\\.h$"   (".c" ".cc" ".C" ".CC" ".cxx" ".cpp"))
+    ("\\.c\\'"   (".h"))
+    ("\\.h\\'"   (".c" ".cc" ".C" ".CC" ".cxx" ".cpp"))
+
+    ("\\.C\\'"   (".H"  ".hh" ".h"))
+    ("\\.H\\'"   (".C"  ".CC"))
 
-    ("\\.C$"   (".H"  ".hh" ".h"))
-    ("\\.H$"   (".C"  ".CC"))
+    ("\\.CC\\'"  (".HH" ".H"  ".hh" ".h"))
+    ("\\.HH\\'"  (".CC"))
+
+    ("\\.c\\+\\+\\'" (".h++" ".hh" ".h"))
+    ("\\.h\\+\\+\\'" (".c++"))
 
-    ("\\.CC$"  (".HH" ".H"  ".hh" ".h"))
-    ("\\.HH$"  (".CC"))
+    ("\\.cpp\\'" (".hpp" ".hh" ".h"))
+    ("\\.hpp\\'" (".cpp"))
 
-    ("\\.cxx$" (".hh" ".h"))
-    ("\\.cpp$" (".hh" ".h"))
-    )
+    ("\\.cxx\\'" (".hxx" ".hh" ".h"))
+    ("\\.hxx\\'" (".cxx")))
   "*Alist of extensions to find given the current file's extension.
 
 This list should contain the most used extensions before the others,