diff options
| author | Gerd Moellmann | 2000-04-27 10:47:45 +0000 |
|---|---|---|
| committer | Gerd Moellmann | 2000-04-27 10:47:45 +0000 |
| commit | c02279de381400c639e33fe89f138f761b8a8fcb (patch) | |
| tree | 507cb539195129f4fb504522c7ae5a96b2500429 /src | |
| parent | 1edb5ce2f60031d926127be2d75f66eba4a343b3 (diff) | |
| download | emacs-c02279de381400c639e33fe89f138f761b8a8fcb.tar.gz emacs-c02279de381400c639e33fe89f138f761b8a8fcb.zip | |
(print_error_message): Print data of `end-of-file'
with Fprinc instead of Fprin1.
Diffstat (limited to 'src')
| -rw-r--r-- | src/print.c | 27 |
1 files changed, 17 insertions, 10 deletions
diff --git a/src/print.c b/src/print.c index 6603525d3d8..be2eee4e5cf 100644 --- a/src/print.c +++ b/src/print.c | |||
| @@ -858,8 +858,8 @@ DEFUN ("error-message-string", Ferror_message_string, Serror_message_string, | |||
| 858 | return value; | 858 | return value; |
| 859 | } | 859 | } |
| 860 | 860 | ||
| 861 | /* Print an error message for the error DATA | 861 | /* Print an error message for the error DATA onto Lisp output stream |
| 862 | onto Lisp output stream STREAM (suitable for the print functions). */ | 862 | STREAM (suitable for the print functions). */ |
| 863 | 863 | ||
| 864 | void | 864 | void |
| 865 | print_error_message (data, stream) | 865 | print_error_message (data, stream) |
| @@ -874,15 +874,17 @@ print_error_message (data, stream) | |||
| 874 | if (EQ (errname, Qerror)) | 874 | if (EQ (errname, Qerror)) |
| 875 | { | 875 | { |
| 876 | data = Fcdr (data); | 876 | data = Fcdr (data); |
| 877 | if (!CONSP (data)) data = Qnil; | 877 | if (!CONSP (data)) |
| 878 | data = Qnil; | ||
| 878 | errmsg = Fcar (data); | 879 | errmsg = Fcar (data); |
| 879 | file_error = Qnil; | 880 | file_error = Qnil; |
| 880 | } | 881 | } |
| 881 | else | 882 | else |
| 882 | { | 883 | { |
| 884 | Lisp_Object error_conditions; | ||
| 883 | errmsg = Fget (errname, Qerror_message); | 885 | errmsg = Fget (errname, Qerror_message); |
| 884 | file_error = Fmemq (Qfile_error, | 886 | error_conditions = Fget (errname, Qerror_conditions); |
| 885 | Fget (errname, Qerror_conditions)); | 887 | file_error = Fmemq (Qfile_error, error_conditions); |
| 886 | } | 888 | } |
| 887 | 889 | ||
| 888 | /* Print an error message including the data items. */ | 890 | /* Print an error message including the data items. */ |
| @@ -900,18 +902,23 @@ print_error_message (data, stream) | |||
| 900 | else | 902 | else |
| 901 | write_string_1 ("peculiar error", -1, stream); | 903 | write_string_1 ("peculiar error", -1, stream); |
| 902 | 904 | ||
| 903 | for (i = 0; CONSP (tail); tail = Fcdr (tail), i++) | 905 | for (i = 0; CONSP (tail); tail = XCDR (tail), i++) |
| 904 | { | 906 | { |
| 907 | Lisp_Object obj; | ||
| 908 | |||
| 905 | write_string_1 (i ? ", " : ": ", 2, stream); | 909 | write_string_1 (i ? ", " : ": ", 2, stream); |
| 906 | if (!NILP (file_error)) | 910 | obj = XCAR (tail); |
| 907 | Fprinc (Fcar (tail), stream); | 911 | if (!NILP (file_error) || EQ (errname, Qend_of_file)) |
| 912 | Fprinc (obj, stream); | ||
| 908 | else | 913 | else |
| 909 | Fprin1 (Fcar (tail), stream); | 914 | Fprin1 (obj, stream); |
| 910 | } | 915 | } |
| 916 | |||
| 911 | UNGCPRO; | 917 | UNGCPRO; |
| 912 | } | 918 | } |
| 913 | |||
| 914 | 919 | ||
| 920 | |||
| 921 | |||
| 915 | /* | 922 | /* |
| 916 | * The buffer should be at least as large as the max string size of the | 923 | * The buffer should be at least as large as the max string size of the |
| 917 | * largest float, printed in the biggest notation. This is undoubtedly | 924 | * largest float, printed in the biggest notation. This is undoubtedly |