X-Git-Url: https://code.delx.au/gnu-emacs/blobdiff_plain/49f70d46ea38ceb7a501594db7f6ea35e19681aa..4b9ac23960d2998f899287ffcf696ad33b63a69a:/lisp/progmodes/cmacexp.el?ds=sidebyside diff --git a/lisp/progmodes/cmacexp.el b/lisp/progmodes/cmacexp.el index d50fb49f03..007619d31f 100644 --- a/lisp/progmodes/cmacexp.el +++ b/lisp/progmodes/cmacexp.el @@ -1,9 +1,9 @@ ;;; cmacexp.el --- expand C macros in a region -;; Copyright (C) 1992, 1994, 1996, 2000, 2001, 2002, 2003, 2004, 2005, -;; 2006, 2007, 2008, 2009, 2010, 2011, 2012 Free Software Foundation, Inc. +;; Copyright (C) 1992, 1994, 1996, 2000-2016 Free Software Foundation, +;; Inc. -;; Author: Francesco Potorti` +;; Author: Francesco Potortì ;; Adapted-By: ESR ;; Keywords: c @@ -50,7 +50,7 @@ ;; INSTALLATION ====================================================== -;; Put the following in your ~/.emacs file. +;; Put the following in your init file. ;; If you want the *Macroexpansion* window to be not higher than ;; necessary: @@ -70,7 +70,7 @@ ;; BUG REPORTS ======================================================= ;; Please report bugs, suggestions, complaints and so on to -;; pot@gnu.org (Francesco Potorti`). +;; bug-gnu-emacs@gnu.org and pot@gnu.org (Francesco Potortì). ;; IMPROVEMENTS OVER emacs 18.xx cmacexp.el ========================== @@ -81,7 +81,7 @@ ;; making comments visible in the expansion. ;; - All work is done in core memory, no need for temporary files. -;; ACKNOWLEDGEMENTS ================================================== +;; ACKNOWLEDGMENTS =================================================== ;; A lot of thanks to Don Maszle who did a great work of testing, bug ;; reporting and suggestion of new features. This work has been @@ -107,12 +107,12 @@ (defcustom c-macro-shrink-window-flag nil - "*Non-nil means shrink the *Macroexpansion* window to fit its contents." + "Non-nil means shrink the *Macroexpansion* window to fit its contents." :type 'boolean :group 'c-macro) (defcustom c-macro-prompt-flag nil - "*Non-nil makes `c-macro-expand' prompt for preprocessor arguments." + "Non-nil makes `c-macro-expand' prompt for preprocessor arguments." :type 'boolean :group 'c-macro) @@ -142,7 +142,7 @@ option, or to set an equivalent one." :group 'c-macro) (defcustom c-macro-cppflags "" - "*Preprocessor flags used by `c-macro-expand'." + "Preprocessor flags used by `c-macro-expand'." :type 'string :group 'c-macro) @@ -364,8 +364,8 @@ Optional arg DISPLAY non-nil means show messages in the echo area." ;; Find and delete the mark of the start of the expansion. ;; Look for `# nn "file.c"' lines and delete them. (goto-char (point-min)) - (search-forward startmarker) - (delete-region 1 (point))) + (if (search-forward startmarker nil t) + (delete-region 1 (point)))) (while (re-search-forward (concat "^# [0-9]+ \"" (regexp-quote filename) "\"") nil t) @@ -389,8 +389,9 @@ Optional arg DISPLAY non-nil means show messages in the echo area." ;; Put the messages inside a comment, so they won't get in ;; the way of font-lock, highlighting etc. (insert - (format "/* Preprocessor terminated with status %s\n\n Messages from `%s\':\n\n" - exit-status cppcommand)) + (format + "/* Preprocessor terminated with status %s\n\n Messages from '%s':\n\n" + exit-status cppcommand)) (goto-char (+ (point) (nth 1 (insert-file-contents tempname)))) (insert "\n\n*/\n"))) @@ -403,5 +404,4 @@ Optional arg DISPLAY non-nil means show messages in the echo area." ;; Cleanup. (kill-buffer outbuf)))) -;; arch-tag: 4f20253c-71ef-4e6d-a774-19087060910e ;;; cmacexp.el ends here