aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuanma Barranquero2002-07-26 07:58:04 +0000
committerJuanma Barranquero2002-07-26 07:58:04 +0000
commit6dc049b29b62f17c5d78267e43c8dcecbf0ed103 (patch)
treefb05c029ca516a8033359ede7385f90f4a84cd5d
parente7a4fab7308c26c48888e317bbf89cd4ab941737 (diff)
downloademacs-6dc049b29b62f17c5d78267e43c8dcecbf0ed103.tar.gz
emacs-6dc049b29b62f17c5d78267e43c8dcecbf0ed103.zip
(warning-levels): Doc fix.
(warning-suppress-log-types): Fix typo. (display-warning): Fix typo. Remove useless asignment to free variable `group-string'.
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/warnings.el14
2 files changed, 11 insertions, 8 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index d5477951ee3..0517430f1b4 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,6 +1,9 @@
12002-07-26 Juanma Barranquero <lektu@terra.es> 12002-07-26 Juanma Barranquero <lektu@terra.es>
2 2
3 * warnings.el (lwarn, warn): Doc fix. 3 * warnings.el (lwarn, warn, warning-levels): Doc fix.
4 (warning-suppress-log-types): Fix typo.
5 (display-warning): Fix typo. Remove useless asignment to free variable
6 `group-string'.
4 7
52002-07-25 Markus Rost <rost@math.ohio-state.edu> 82002-07-25 Markus Rost <rost@math.ohio-state.edu>
6 9
diff --git a/lisp/warnings.el b/lisp/warnings.el
index 9f202fd24a3..db371653e8d 100644
--- a/lisp/warnings.el
+++ b/lisp/warnings.el
@@ -34,7 +34,7 @@
34 (:error "Error%s: ") 34 (:error "Error%s: ")
35 (:warning "Warning%s: ") 35 (:warning "Warning%s: ")
36 (:debug "Debug%s: ")) 36 (:debug "Debug%s: "))
37 "List of severity level definitions for `define-warnings'. 37 "List of severity level definitions for `display-warning'.
38Each element looks like (LEVEL STRING FUNCTION) and 38Each element looks like (LEVEL STRING FUNCTION) and
39defines LEVEL as a severity level. STRING is the description 39defines LEVEL as a severity level. STRING is the description
40to use in the buffer, and FUNCTION (which may be omitted) 40to use in the buffer, and FUNCTION (which may be omitted)
@@ -86,7 +86,7 @@ the warning is completely ignored.
86The element must match the first elements of GROUP. 86The element must match the first elements of GROUP.
87Thus, (foo bar) as an element matches (foo bar) 87Thus, (foo bar) as an element matches (foo bar)
88or (foo bar ANYTHING...) as GROUP. 88or (foo bar ANYTHING...) as GROUP.
89If GROUP is a symbol FOO, that is equivalent to the list (FOO) 89If GROUP is a symbol FOO, that is equivalent to the list (FOO),
90so only the element (FOO) will match it." 90so only the element (FOO) will match it."
91 :group 'warnings 91 :group 'warnings
92 :type '(repeat (repeat symbol)) 92 :type '(repeat (repeat symbol))
@@ -121,7 +121,7 @@ the beginning of the warning.")
121 (let* ((elt (assq level warning-levels)) 121 (let* ((elt (assq level warning-levels))
122 (link (memq elt warning-levels))) 122 (link (memq elt warning-levels)))
123 (length link))) 123 (length link)))
124 124
125(defvar warning-series nil 125(defvar warning-series nil
126 "Non-nil means treat multiple `display-warning' calls as a series. 126 "Non-nil means treat multiple `display-warning' calls as a series.
127An integer is a position in the warnings buffer 127An integer is a position in the warnings buffer
@@ -171,7 +171,7 @@ SUPPRESS-LIST is the list of kinds of warnings to suppress."
171;;;###autoload 171;;;###autoload
172(defun display-warning (group message &optional level buffer-name) 172(defun display-warning (group message &optional level buffer-name)
173 "Display a warning message, MESSAGE. 173 "Display a warning message, MESSAGE.
174GROUP should be a custom group name (a symbol). 174GROUP should be a custom group name (a symbol),
175or else a list of symbols whose first element is a custom group name. 175or else a list of symbols whose first element is a custom group name.
176\(The rest of the symbols represent subcategories, for warning purposes 176\(The rest of the symbols represent subcategories, for warning purposes
177only, and you can use whatever symbols you like.) 177only, and you can use whatever symbols you like.)
@@ -215,8 +215,8 @@ See also `warning-series', `warning-prefix-function' and
215 (if warning-prefix-function 215 (if warning-prefix-function
216 (setq level-info (funcall warning-prefix-function 216 (setq level-info (funcall warning-prefix-function
217 level level-info))) 217 level level-info)))
218 (setq group-string (format warning-group-format groupname)) 218 (insert (format (nth 1 level-info)
219 (insert (format (nth 1 level-info) group-string) 219 (format warning-group-format groupname))
220 message) 220 message)
221 (newline) 221 (newline)
222 (when (and warning-fill-prefix (not (string-match "\n" message))) 222 (when (and warning-fill-prefix (not (string-match "\n" message)))
@@ -238,7 +238,7 @@ See also `warning-series', `warning-prefix-function' and
238 ;; Interactively, decide whether the warning merits 238 ;; Interactively, decide whether the warning merits
239 ;; immediate display. 239 ;; immediate display.
240 (or (< (warning-numeric-level level) 240 (or (< (warning-numeric-level level)
241 (warning-numeric-level warning-minimum-level)) 241 (warning-numeric-level warning-minimum-level))
242 (warning-suppress-p group warning-suppress-types) 242 (warning-suppress-p group warning-suppress-types)
243 (let ((window (display-buffer buffer))) 243 (let ((window (display-buffer buffer)))
244 (when warning-series 244 (when warning-series