Mercurial > emacs
changeset 14606:b0a537848bb6
Added provide.
author | Roland McGrath <roland@gnu.org> |
---|---|
date | Wed, 21 Feb 1996 07:29:19 +0000 |
parents | 80196bfd8b94 |
children | 3c86ac6a871a |
files | lisp/progmodes/c-mode.el |
diffstat | 1 files changed, 22 insertions(+), 20 deletions(-) [+] |
line wrap: on
line diff
--- a/lisp/progmodes/c-mode.el Wed Feb 21 01:45:21 1996 +0000 +++ b/lisp/progmodes/c-mode.el Wed Feb 21 07:29:19 1996 +0000 @@ -183,22 +183,22 @@ ;; This is actually the expression for C++ mode, but it's used for C too. (defvar c-imenu-generic-expression - (` + (` ((nil - (, + (, (concat "^" ; beginning of line is required "\\(template[ \t]*<[^>]+>[ \t]*\\)?" ; there may be a "template <...>" "\\([a-zA-Z0-9_:]+[ \t]+\\)?" ; type specs; there can be no "\\([a-zA-Z0-9_:]+[ \t]+\\)?" ; more than 3 tokens, right? - + "\\(" ; last type spec including */& "[a-zA-Z0-9_:]+" "\\([ \t]*[*&]+[ \t]*\\|[ \t]+\\)" ; either pointer/ref sign or whitespace "\\)?" ; if there is a last type spec "\\(" ; name; take that into the imenu entry "[a-zA-Z0-9_:~]+" ; member function, ctor or dtor... - ; (may not contain * because then + ; (may not contain * because then ; "a::operator char*" would become "char*"!) "\\|" "\\([a-zA-Z0-9_:~]*::\\)?operator" @@ -209,10 +209,10 @@ ; catch cases with () inside the parentheses ; surrounding the parameters ; (like "int foo(int a=bar()) {...}" - - )) 6) - ("Class" - (, (concat + + )) 6) + ("Class" + (, (concat "^" ; beginning of line is required "\\(template[ \t]*<[^>]+>[ \t]*\\)?" ; there may be a "template <...>" "class[ \t]+" @@ -223,20 +223,20 @@ ;; Uncomment if you want to find these too. It will be a bit slower gathering ;; the indexes. ; ("Prototypes" -; (, +; (, ; (concat ; "^" ; beginning of line is required ; "\\(template[ \t]*<[^>]+>[ \t]*\\)?" ; there may be a "template <...>" ; "\\([a-zA-Z0-9_:]+[ \t]+\\)?" ; type specs; there can be no ; "\\([a-zA-Z0-9_:]+[ \t]+\\)?" ; more than 3 tokens, right? - + ; "\\(" ; last type spec including */& ; "[a-zA-Z0-9_:]+" ; "\\([ \t]*[*&]+[ \t]*\\|[ \t]+\\)" ; either pointer/ref sign or whitespace ; "\\)?" ; if there is a last type spec ; "\\(" ; name; take that into the imenu entry ; "[a-zA-Z0-9_:~]+" ; member function, ctor or dtor... -; ; (may not contain * because then +; ; (may not contain * because then ; ; "a::operator char*" would become "char*"!) ; "\\|" ; "\\([a-zA-Z0-9_:~]*::\\)?operator" @@ -246,8 +246,8 @@ ; ; the (...) Can't ; ; catch cases with () inside the parentheses ; ; surrounding the parameters -; ; (like "int foo(int a=bar());" -; )) 6) +; ; (like "int foo(int a=bar());" +; )) 6) ; ("Struct" ; (, (concat ; "^" ; beginning of line is required @@ -420,7 +420,7 @@ (paragraph-start ;; Lines containing just a comment start or just an end ;; should not be filled into paragraphs they are next to. - (concat + (concat paragraph-start "\\|[ \t]*/\\*[ \t]*$\\|[ \t]*\\*/[ \t]*$\\|[ \t/*]*$")) (paragraph-separate @@ -531,7 +531,7 @@ (paragraph-start ;; Lines containing just a comment start or just an end ;; should not be filled into paragraphs they are next to. - (concat + (concat paragraph-start "\\|[ \t]*/\\*[ \t]*$\\|[ \t]*\\*/[ \t]*$\\|[ \t/*]*$")) (paragraph-separate @@ -549,8 +549,8 @@ (if comment-start-place (goto-char comment-start-place) (search-backward "/*")) - ;; Protect text before the comment start - ;; by excluding it. Add spaces to bring back + ;; Protect text before the comment start + ;; by excluding it. Add spaces to bring back ;; proper indentation of that point. (let ((column (current-column))) (prog1 (point) @@ -971,7 +971,7 @@ ;; The first following code counts ;; if it is before the line we want to indent. (and (< (point) indent-point) - (- + (- (if (> colon-line-end (point)) (- (current-indentation) c-label-offset) (current-column)) @@ -1174,7 +1174,7 @@ (not (re-search-forward "[;{}]" end t))))))) (re-search-backward "[;}]") (forward-char 1)) - (error + (error (let ((beg (point))) (backward-up-list -1) (let ((end (point))) @@ -1511,7 +1511,7 @@ With no argument, inserts backslashes and aligns existing backslashes. With an argument, deletes the backslashes. -This function does not modify the last line of the region if the region ends +This function does not modify the last line of the region if the region ends right at the start of the following line; it does not modify blank lines at the start of the region. So you can put the region around an entire macro definition and conveniently use this command." @@ -1644,5 +1644,7 @@ (setq count (+ count increment)))) (push-mark) (goto-char new))) + +(provide 'c-mode) ;;; c-mode.el ends here