From: maqiyuan Date: Sat, 1 Feb 2014 12:55:05 +0000 (+0800) Subject: fatal_eror: str_number -> char *. X-Git-Url: http://git.osdn.net/view?a=commitdiff_plain;h=677212c653724fe6f2c21d7328cc7cb036e22fc7;p=putex%2Fputex.git fatal_eror: str_number -> char *. --- diff --git a/src/texsourc/coerce.h b/src/texsourc/coerce.h index 096ee92..6fc9288 100644 --- a/src/texsourc/coerce.h +++ b/src/texsourc/coerce.h @@ -75,8 +75,8 @@ int jump_out(void); int error(void); #define error_regmem // void fatal_error_(str_number); -int fatal_error_(str_number); -#define fatal_error(s) fatal_error_((str_number) (s)) +int fatal_error_(char *); +#define fatal_error(s) fatal_error_((char *) (s)) #define fatalerror_regmem // void overflow_(str_number, integer); int overflow_(str_number, integer); @@ -917,8 +917,8 @@ void print_write_whatsit_(str_number, halfword); #define print_write_whatsit(s, p) print_write_whatsit_((str_number) (s), (halfword) (p)) void jump_out(void); void error(void); -void fatal_error_(str_number); -#define fatal_error(s) fatal_error_((str_number) (s)) +void fatal_error_(char *); +#define fatal_error(s) fatal_error_((char *) (s)) void overflow_(str_number, integer); #define overflow(s, n) overflow_((str_number) (s), (integer) (n)) void confusion_(str_number); diff --git a/src/texsourc/itex.c b/src/texsourc/itex.c index 279a503..629d89d 100644 --- a/src/texsourc/itex.c +++ b/src/texsourc/itex.c @@ -2255,7 +2255,7 @@ void final_clean_up (void) print_char(41); /*)*/ } while(cond_ptr != 0){ - print_nl(40); /*(*/ + print_nl("("); /*(*/ print_esc(1271); /* end occurred */ print(1273); /* when */ print_cmd_chr(105, cur_if); /* i */ @@ -2302,7 +2302,7 @@ void final_clean_up (void) } #endif /* INITEX */ if (!is_initex) /* 2000/March/3 */ - print_nl(" (\dump is performed only by INITEX)"); /* */ + print_nl(" (\\dump is performed only by INITEX)"); /* */ } } diff --git a/src/texsourc/tex0.c b/src/texsourc/tex0.c index 9473a20..9b300b6 100644 --- a/src/texsourc/tex0.c +++ b/src/texsourc/tex0.c @@ -595,15 +595,11 @@ lab22: /* loop */ print_ln (); } -void fatal_error_(str_number s) +void fatal_error_(char * s) { normalize_selector (); print_err("Emergency stop"); - //help1(""); - { - help_ptr = 1; - help_line[0] = ""; //s; // given string goes into help line - } + help1(s); { if(interaction == 3)interaction = 2; if(log_opened){ @@ -996,7 +992,7 @@ void term_input (int promptstr, int nhelplines) flag = input_ln(stdin, true); #endif if(! flag){ - fatal_error(261); /* End of file on the terminal! */ + fatal_error("End of file on the terminal!"); /* */ return; // abort_flag set } term_offset = 0; @@ -1050,7 +1046,7 @@ void pause_for_instructions (void) incr(selector); print_err("Interruption"); help3("You rang?", - "Try to insert some instructions for me (e.g.,`I\showlists'),", + "Try to insert some instructions for me (e.g.,`I\\showlists'),", "unless you just want to quit by typing `X'."); deletions_allowed = false; error (); diff --git a/src/texsourc/tex2.c b/src/texsourc/tex2.c index 43134f9..240cd8a 100644 --- a/src/texsourc/tex2.c +++ b/src/texsourc/tex2.c @@ -482,7 +482,7 @@ void end_token_list (void) else if(cur_input.index_field == 1) if(align_state > 500000L)align_state = 0; else { - fatal_error(592); /* (interwoven alignment preambles are not allowed) */ + fatal_error("(interwoven alignment preambles are not allowed)"); /* */ return; // abort_flag set } { @@ -2198,7 +2198,7 @@ lab20: ) incr(cur_input.limit_field); if(cur_input.limit_field == cur_input.start_field) - print_nl("(Please type a command or say `\end')"); /* */ + print_nl("(Please type a command or say `\\end')"); /* */ print_ln (); first = cur_input.start_field; { @@ -2217,7 +2217,7 @@ lab20: cur_input.loc_field = cur_input.start_field; } else { - fatal_error(614); /* *** (job aborted, no legal \end found) */ + fatal_error("*** (job aborted, no legal \\end found)"); /* */ return; // abort_flag set } } @@ -2290,7 +2290,7 @@ lab20: if(align_state == 0) { if(scanner_status == 4){ - fatal_error(592); /* (interwoven alignment preambles are not allowed) */ + fatal_error("(interwoven alignment preambles are not allowed)"); /* */ return; // abort_flag set } diff --git a/src/texsourc/tex3.c b/src/texsourc/tex3.c index b2b7c05..2130ef1 100644 --- a/src/texsourc/tex3.c +++ b/src/texsourc/tex3.c @@ -915,7 +915,7 @@ void read_toks_(integer n, halfword r) n = -1; } else { - fatal_error(750); /* *** (cannot \read from terminal in nonstop modes) */ + fatal_error("*** (cannot \\read from terminal in nonstop modes)"); /* */ return; // abort_flag set } else if(read_open[m]== 1) @@ -1769,7 +1769,7 @@ void prompt_file_name_(str_number s, str_number e)/* s - what can't be found, e print_nl("Please type another "); /* */ print(s); if(interaction < 2){ - fatal_error(787); /* *** (job aborted, file error in nonstop mode) */ + fatal_error("*** (job aborted, file error in nonstop mode)"); /* */ return; // abort_flag set } if (! knuth_flag) diff --git a/src/texsourc/tex5.c b/src/texsourc/tex5.c index c5fbcd4..a95186b 100644 --- a/src/texsourc/tex5.c +++ b/src/texsourc/tex5.c @@ -1101,7 +1101,7 @@ void get_preamble_token (void) } } if(cur_cmd == 9){ - fatal_error(592); /* (interwoven alignment preambles are not allowed) */ + fatal_error("(interwoven alignment preambles are not allowed)"); /* */ return; // abort_flag set } if((cur_cmd == 75)&&(cur_chr == (hash_size + 793))) @@ -1127,7 +1127,7 @@ void init_align (void) print_err("Improper "); print_esc(517); /* halign */ print(888); /* inside $$ */ - help3("Displays can use special alignments (like \eqalignno)", + help3("Displays can use special alignments (like \\eqalignno)", "only if nothing but the alignment itself is between $$'s.", "So I've deleted the formulas that preceded this alignment."); error (); @@ -1641,7 +1641,7 @@ bool fin_col (void) return 0; // abort_flag set } if(align_state < 500000L) { /* ??? */ - fatal_error(592); /* (interwoven alignment preambles are not allowed) */ + fatal_error("(interwoven alignment preambles are not allowed)"); /* */ return 0; // abort_flag set } p = mem[q].hh.v.RH; /* p <- link(q) p.791 */ diff --git a/src/texsourc/tex6.c b/src/texsourc/tex6.c index e51ed83..a37f571 100644 --- a/src/texsourc/tex6.c +++ b/src/texsourc/tex6.c @@ -52,7 +52,7 @@ halfword finite_shrink_(halfword p) noshrinkerroryet = false; print_err("Infinite glue shrinkage found in a paragraph"); help5("The paragraph just ended includes some glue that has", - "infinite shrinkability, e.g., `\hskip 0pt minus 1fil'.", + "infinite shrinkability, e.g., `\\hskip 0pt minus 1fil'.", "Such glue doesn't belong there---it allows a paragraph", "of any length to fit on one line. But it's safe to proceed,", "since the offensive shrinkability has been made finite."); diff --git a/src/texsourc/tex7.c b/src/texsourc/tex7.c index d7df252..fe75e86 100644 --- a/src/texsourc/tex7.c +++ b/src/texsourc/tex7.c @@ -567,7 +567,7 @@ void extra_right_brace (void) } help5("I've deleted a group-closing symbol because it seems to be", "spurious, as in `$x}$'. But perhaps the } is legitimate and", - "you forgot something else, as in `\hbox{$x}'. In such cases", + "you forgot something else, as in `\\hbox{$x}'. In such cases", "the way to recover is to insert both the forgotten and the", "deleted material, e.g., by typing `I$}'."); error (); @@ -1059,7 +1059,7 @@ void unpackage (void) { print_err("Incompatible list can't be unboxed"); help3("Sorry, Pandora. (You sneaky devil.)", - "I refuse to unbox an \hbox in vertical mode or vice versa.", + "I refuse to unbox an \\hbox in vertical mode or vice versa.", "And I can't open any boxes in math mode."); error (); return; @@ -1693,7 +1693,7 @@ void math_ac (void) print_err("Please use "); print_esc(520); /* mathaccent */ print(1134); /* for accents in math mode */ - help2("I'm changing \accent to \mathaccent here; wish me luck.", + help2("I'm changing \\accent to \\mathaccent here; wish me luck.", "(Accents are not the same in formulas as they are in text.)"); error (); }