diff options
| author | Juanma Barranquero | 2002-07-26 07:58:04 +0000 |
|---|---|---|
| committer | Juanma Barranquero | 2002-07-26 07:58:04 +0000 |
| commit | 6dc049b29b62f17c5d78267e43c8dcecbf0ed103 (patch) | |
| tree | fb05c029ca516a8033359ede7385f90f4a84cd5d | |
| parent | e7a4fab7308c26c48888e317bbf89cd4ab941737 (diff) | |
| download | emacs-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/ChangeLog | 5 | ||||
| -rw-r--r-- | lisp/warnings.el | 14 |
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 @@ | |||
| 1 | 2002-07-26 Juanma Barranquero <lektu@terra.es> | 1 | 2002-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 | ||
| 5 | 2002-07-25 Markus Rost <rost@math.ohio-state.edu> | 8 | 2002-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'. |
| 38 | Each element looks like (LEVEL STRING FUNCTION) and | 38 | Each element looks like (LEVEL STRING FUNCTION) and |
| 39 | defines LEVEL as a severity level. STRING is the description | 39 | defines LEVEL as a severity level. STRING is the description |
| 40 | to use in the buffer, and FUNCTION (which may be omitted) | 40 | to use in the buffer, and FUNCTION (which may be omitted) |
| @@ -86,7 +86,7 @@ the warning is completely ignored. | |||
| 86 | The element must match the first elements of GROUP. | 86 | The element must match the first elements of GROUP. |
| 87 | Thus, (foo bar) as an element matches (foo bar) | 87 | Thus, (foo bar) as an element matches (foo bar) |
| 88 | or (foo bar ANYTHING...) as GROUP. | 88 | or (foo bar ANYTHING...) as GROUP. |
| 89 | If GROUP is a symbol FOO, that is equivalent to the list (FOO) | 89 | If GROUP is a symbol FOO, that is equivalent to the list (FOO), |
| 90 | so only the element (FOO) will match it." | 90 | so 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. |
| 127 | An integer is a position in the warnings buffer | 127 | An 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. |
| 174 | GROUP should be a custom group name (a symbol). | 174 | GROUP should be a custom group name (a symbol), |
| 175 | or else a list of symbols whose first element is a custom group name. | 175 | or 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 |
| 177 | only, and you can use whatever symbols you like.) | 177 | only, 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 |