Back to index

tetex-bin  3.0
tie.c
Go to the documentation of this file.
00001 #define banner "This is TIE, CWEB Version 2.4."
00002 #define copyright  \
00003 "Copyright (c) 1989,1992 by THD/ITI. All rights reserved." \
00004  \
00005 
00006 #define incr(v)v+= 1
00007 #define decr(v)v-= 1
00008 #define loop while(1)
00009 #define do_nothing 
00010 #define false 0
00011 #define true 1
00012 #define spotless 0
00013 #define troublesome 1
00014 #define fatal 2 \
00015 
00016 #define first_text_char 0
00017 #define last_text_char 255 \
00018 
00019 #define map_xchr(c)(text_char)(c) \
00020 
00021 #define map_xord(c)(ASCII_Code)(c) \
00022  \
00023 
00024 #define tab_mark 9
00025 #define nl_mark 10
00026 #define form_feed 12 \
00027  \
00028 
00029 #define term_out stdout
00030 #define print(a)fprintf(term_out,a)
00031 #define print2(a,b)fprintf(term_out,a,b)
00032 #define print3(a,b,c)fprintf(term_out,a,b,c)
00033 #define print_c(v)fputc(v,term_out);
00034 #define new_line(v)fputc('\n',v)
00035 #define term_new_line new_line(term_out) \
00036 
00037 #define print_ln(v){fprintf(term_out,v);term_new_line;} \
00038 
00039 #define print2_ln(a,b){print2(a,b);term_new_line;}
00040 #define print3_ln(a,b,c){print3(a,b,c);term_new_line;} \
00041 
00042 #define print_nl(v){term_new_line;print(v);} \
00043 
00044 #define print2_nl(a,b){term_new_line;print2(a,b);} \
00045  \
00046 
00047 #define update_terminal fflush(term_out) \
00048  \
00049  \
00050  \
00051  \
00052 
00053 #define error_loc(m)err_loc(m);history= troublesome;}
00054 #define err_print(m){print_nl(m);error_loc \
00055 
00056 #define fatal_error(m){ \
00057 print(m);print_c('.');history= fatal; \
00058 term_new_line;jump_out(); \
00059 } \
00060  \
00061 
00062 #define jump_out()exit(1) \
00063  \
00064  \
00065  \
00066  \
00067 
00068 #define none (max_file_index+1) \
00069 
00070 /*2:*/
00071 #line 112 "tie.w"
00072 
00073 /*15:*/
00074 #line 478 "tie.w"
00075 
00076 #include <stdio.h>
00077 
00078 
00079 /*:15*//*16:*/
00080 #line 486 "tie.w"
00081 
00082 #ifdef __STDC__
00083 #include <stdlib.h>
00084 #else
00085 #include <malloc.h>
00086 #endif
00087 
00088 /*:16*/
00089 #line 113 "tie.w"
00090 
00091 /*5:*/
00092 #line 142 "tie.w"
00093 
00094 #define buf_size 512 
00095 #define max_file_index 9
00096 
00097 
00098 
00099 
00100 /*:5*/
00101 #line 114 "tie.w"
00102 
00103 /*4:*/
00104 #line 133 "tie.w"
00105 
00106 typedef int boolean;
00107 typedef char*string;
00108 
00109 
00110 /*:4*//*7:*/
00111 #line 224 "tie.w"
00112 
00113 #define max_ASCII (126+1)
00114 typedef unsigned char ASCII_Code;
00115 
00116 
00117 
00118 /*:7*//*8:*/
00119 #line 250 "tie.w"
00120 
00121 typedef unsigned char text_char;
00122 typedef FILE*text_file;
00123 
00124 
00125 /*:8*//*18:*/
00126 #line 529 "tie.w"
00127 
00128 #define search 0
00129 #define test 1
00130 #define reading 2
00131 #define ignore 3
00132 typedef int in_file_modes;
00133 #define unknown 0
00134 #define master 1
00135 #define chf 2
00136 typedef int file_types;
00137 
00138 
00139 /*:18*//*19:*/
00140 #line 547 "tie.w"
00141 
00142 #define normal 0
00143 #define pre 1
00144 #define post 2
00145 typedef int out_md_type;
00146 
00147 
00148 /*:19*//*20:*/
00149 #line 557 "tie.w"
00150 
00151 typedef int buffer_index;
00152 typedef int file_index;
00153 
00154 
00155 /*:20*//*21:*/
00156 #line 566 "tie.w"
00157 
00158 typedef struct _idsc{
00159 string name_of_file;
00160 ASCII_Code buffer[buf_size];
00161 in_file_modes mode;
00162 long line;
00163 file_types type_of_file;
00164 buffer_index limit;
00165 text_file the_file;
00166 }input_description;
00167 
00168 
00169 /*:21*/
00170 #line 115 "tie.w"
00171 
00172 /*6:*/
00173 #line 159 "tie.w"
00174 
00175 static int history= spotless;
00176 
00177 
00178 
00179 /*:6*//*9:*/
00180 #line 270 "tie.w"
00181 
00182 static ASCII_Code xord[last_text_char+1];
00183 
00184 static text_char xchr[max_ASCII+1];
00185 
00186 
00187 
00188 /*:9*//*22:*/
00189 #line 582 "tie.w"
00190 
00191 static file_index actual_input,test_input,no_ch;
00192 static file_types prod_chf= unknown;
00193 static out_md_type out_mode;
00194 
00195 
00196 /*:22*//*23:*/
00197 #line 594 "tie.w"
00198 
00199 static input_description*input_organization[max_file_index+1];
00200 
00201 
00202 
00203 
00204 
00205 /*:23*//*26:*/
00206 #line 641 "tie.w"
00207 
00208 static boolean input_has_ended= false;
00209 
00210 
00211 /*:26*//*35:*/
00212 #line 801 "tie.w"
00213 
00214 static text_file out_file;
00215 static string out_name;
00216 
00217 
00218 /*:35*/
00219 #line 116 "tie.w"
00220 
00221 /*31:*/
00222 #line 744 "tie.w"
00223 
00224 void err_loc(i)
00225 int i;
00226 {
00227 print3_ln(" (file %s, l.%ld).",
00228 input_organization[i]->name_of_file,
00229 input_organization[i]->line);
00230 }
00231 
00232 
00233 /*:31*/
00234 #line 117 "tie.w"
00235 
00236 /*24:*/
00237 #line 616 "tie.w"
00238 
00239 void get_line(i)
00240 file_index i;
00241 {register input_description*inp_desc= input_organization[i];
00242 if(inp_desc->mode==ignore)return;
00243 if(feof(inp_desc->the_file))
00244 /*25:*/
00245 #line 630 "tie.w"
00246 
00247 {
00248 inp_desc->mode= ignore;
00249 inp_desc->limit= -1;
00250 if(inp_desc->type_of_file==master)input_has_ended= true;
00251 return;
00252 }
00253 
00254 
00255 /*:25*/
00256 #line 622 "tie.w"
00257 
00258 /*27:*/
00259 #line 655 "tie.w"
00260 
00261 {int final_limit;
00262 int c;
00263 /*28:*/
00264 #line 679 "tie.w"
00265 
00266 incr(inp_desc->line);
00267 if(inp_desc->type_of_file==master&&inp_desc->line%100==0){
00268 if(inp_desc->line%500==0)print2("%ld",inp_desc->line);
00269 else print_c('.');
00270 update_terminal;
00271 }
00272 
00273 
00274 /*:28*/
00275 #line 659 "tie.w"
00276 
00277 inp_desc->limit= final_limit= 0;
00278 while(inp_desc->limit<buf_size){
00279 c= fgetc(inp_desc->the_file);
00280 /*29:*/
00281 #line 696 "tie.w"
00282 
00283 if(c==EOF){
00284 if(inp_desc->limit<=0){
00285 inp_desc->mode= ignore;
00286 inp_desc->limit= -1;
00287 if(inp_desc->type_of_file==master)input_has_ended= true;
00288 return;
00289 }else{
00290 c= nl_mark;
00291 break;
00292 }
00293 }
00294 
00295 
00296 /*:29*/
00297 #line 664 "tie.w"
00298 
00299 inp_desc->buffer[inp_desc->limit++]= c= map_xord(c);
00300 if(c==nl_mark)break;
00301 if(c!=32&&c!=tab_mark)
00302 final_limit= inp_desc->limit;
00303 }
00304 /*30:*/
00305 #line 712 "tie.w"
00306 
00307 if(c!=nl_mark){
00308 err_print("! Input line too long")(i);
00309 
00310 while((c= fgetc(inp_desc->the_file))!=EOF&&map_xord(c)!=nl_mark)
00311 do_nothing;
00312 }
00313 
00314 
00315 
00316 
00317 
00318 /*:30*/
00319 #line 670 "tie.w"
00320 
00321 inp_desc->limit= final_limit;
00322 }
00323 
00324 
00325 /*:27*/
00326 #line 623 "tie.w"
00327 
00328 }
00329 
00330 
00331 /*:24*//*38:*/
00332 #line 850 "tie.w"
00333 
00334 boolean lines_dont_match(i,j)
00335 file_index i,j;
00336 {
00337 buffer_index k,lmt;
00338 if(input_organization[i]->limit!=input_organization[j]->limit)
00339 return(true);
00340 lmt= input_organization[i]->limit;
00341 for(k= 0;k<lmt;k++)
00342 if(input_organization[i]->buffer[k]!=input_organization[j]->buffer[k])
00343 return(true);
00344 return(false);
00345 }
00346 
00347 
00348 /*:38*//*39:*/
00349 #line 871 "tie.w"
00350 
00351 void init_change_file(i,b)
00352 file_index i;boolean b;
00353 {register input_description*inp_desc= input_organization[i];
00354 /*40:*/
00355 #line 885 "tie.w"
00356 
00357 loop{ASCII_Code c;
00358 get_line(i);
00359 if(inp_desc->mode==ignore)return;
00360 if(inp_desc->limit<2)continue;
00361 if(inp_desc->buffer[0]!=64)continue;
00362 c= inp_desc->buffer[1];
00363 if(c>=88&&c<=90)
00364 c+= 122-90;
00365 if(c==120)break;
00366 if(c==121||c==122)
00367 if(b)
00368 err_print("! Where is the matching @x?")(i);
00369 
00370 }
00371 
00372 
00373 /*:40*/
00374 #line 875 "tie.w"
00375 
00376 /*41:*/
00377 #line 904 "tie.w"
00378 
00379 do{
00380 get_line(i);
00381 if(inp_desc->mode==ignore){
00382 err_print("! Change file ended after @x")(i);
00383 
00384 return;
00385 }
00386 }while(inp_desc->limit<=0);
00387 
00388 
00389 /*:41*/
00390 #line 876 "tie.w"
00391 
00392 }
00393 
00394 
00395 /*:39*//*42:*/
00396 #line 918 "tie.w"
00397 
00398 void put_line(j)
00399 file_index j;
00400 {buffer_index i;
00401 buffer_index lmt;
00402 ASCII_Code*p;
00403 lmt= input_organization[j]->limit;
00404 p= input_organization[j]->buffer;
00405 for(i= 0;i<lmt;i++)fputc(map_xchr(*p++),out_file);
00406 new_line(out_file);
00407 }
00408 
00409 
00410 /*:42*//*43:*/
00411 #line 934 "tie.w"
00412 
00413 boolean e_of_ch_module(i)
00414 file_index i;
00415 {register input_description*inp_desc= input_organization[i];
00416 if(inp_desc->limit<0){
00417 print_nl("! At the end of change file missing @z ");
00418 
00419 print2("%s",input_organization[i]->name_of_file);
00420 term_new_line;
00421 return(true);
00422 }else if(inp_desc->limit>=2)if(inp_desc->buffer[0]==64&&
00423 (inp_desc->buffer[1]==90||inp_desc->buffer[1]==122))
00424 return(true);
00425 return(false);
00426 }
00427 
00428 
00429 /*:43*//*44:*/
00430 #line 954 "tie.w"
00431 
00432 boolean e_of_ch_preamble(i)
00433 file_index i;
00434 {register input_description*inp_desc= input_organization[i];
00435 if(inp_desc->limit>=2&&inp_desc->buffer[0]==64)
00436 if(inp_desc->buffer[1]==89||inp_desc->buffer[1]==121)return(true);
00437 return(false);
00438 }
00439 
00440 
00441 
00442 /*:44*//*55:*/
00443 #line 1157 "tie.w"
00444 
00445 void usage()
00446 {
00447 print("Usage: tie -[mc] outfile master changefile(s)");
00448 term_new_line;
00449 jump_out();
00450 }
00451 
00452 
00453 /*:55*/
00454 #line 118 "tie.w"
00455 
00456 /*59:*/
00457 #line 1235 "tie.w"
00458 
00459 main(argc,argv)
00460 int argc;string*argv;
00461 {{/*12:*/
00462 #line 408 "tie.w"
00463 
00464 int i;
00465 
00466 
00467 /*:12*/
00468 #line 1238 "tie.w"
00469 
00470 /*10:*/
00471 #line 296 "tie.w"
00472 
00473 xchr[32]= ' ';
00474 xchr[33]= '!';
00475 xchr[34]= '\"';
00476 xchr[35]= '#';
00477 xchr[36]= '$';
00478 xchr[37]= '%';
00479 xchr[38]= '&';
00480 xchr[39]= '\'';
00481 xchr[40]= '(';
00482 xchr[41]= ')';
00483 xchr[42]= '*';
00484 xchr[43]= '+';
00485 xchr[44]= ',';
00486 xchr[45]= '-';
00487 xchr[46]= '.';
00488 xchr[47]= '/';
00489 xchr[48]= '0';
00490 xchr[49]= '1';
00491 xchr[50]= '2';
00492 xchr[51]= '3';
00493 xchr[52]= '4';
00494 xchr[53]= '5';
00495 xchr[54]= '6';
00496 xchr[55]= '7';
00497 xchr[56]= '8';
00498 xchr[57]= '9';
00499 xchr[58]= ':';
00500 xchr[59]= ';';
00501 xchr[60]= '<';
00502 xchr[61]= '=';
00503 xchr[62]= '>';
00504 xchr[63]= '?';
00505 xchr[64]= '@';
00506 xchr[65]= 'A';
00507 xchr[66]= 'B';
00508 xchr[67]= 'C';
00509 xchr[68]= 'D';
00510 xchr[69]= 'E';
00511 xchr[70]= 'F';
00512 xchr[71]= 'G';
00513 xchr[72]= 'H';
00514 xchr[73]= 'I';
00515 xchr[74]= 'J';
00516 xchr[75]= 'K';
00517 xchr[76]= 'L';
00518 xchr[77]= 'M';
00519 xchr[78]= 'N';
00520 xchr[79]= 'O';
00521 xchr[80]= 'P';
00522 xchr[81]= 'Q';
00523 xchr[82]= 'R';
00524 xchr[83]= 'S';
00525 xchr[84]= 'T';
00526 xchr[85]= 'U';
00527 xchr[86]= 'V';
00528 xchr[87]= 'W';
00529 xchr[88]= 'X';
00530 xchr[89]= 'Y';
00531 xchr[90]= 'Z';
00532 xchr[91]= '[';
00533 xchr[92]= '\\';
00534 xchr[93]= ']';
00535 xchr[94]= '^';
00536 xchr[95]= '_';
00537 xchr[96]= '`';
00538 xchr[97]= 'a';
00539 xchr[98]= 'b';
00540 xchr[99]= 'c';
00541 xchr[100]= 'd';
00542 xchr[101]= 'e';
00543 xchr[102]= 'f';
00544 xchr[103]= 'g';
00545 xchr[104]= 'h';
00546 xchr[105]= 'i';
00547 xchr[106]= 'j';
00548 xchr[107]= 'k';
00549 xchr[108]= 'l';
00550 xchr[109]= 'm';
00551 xchr[110]= 'n';
00552 xchr[111]= 'o';
00553 xchr[112]= 'p';
00554 xchr[113]= 'q';
00555 xchr[114]= 'r';
00556 xchr[115]= 's';
00557 xchr[116]= 't';
00558 xchr[117]= 'u';
00559 xchr[118]= 'v';
00560 xchr[119]= 'w';
00561 xchr[120]= 'x';
00562 xchr[121]= 'y';
00563 xchr[122]= 'z';
00564 xchr[123]= '{';
00565 xchr[124]= '|';
00566 xchr[125]= '}';
00567 xchr[126]= '~';
00568 xchr[0]= ' ';xchr[0x7F]= ' ';
00569 
00570 
00571 /*:10*//*13:*/
00572 #line 429 "tie.w"
00573 
00574 for(i= 1;i<32;xchr[i++]= ' ');
00575 xchr[tab_mark]= '\t';
00576 xchr[form_feed]= '\f';
00577 xchr[nl_mark]= '\n';
00578 
00579 
00580 /*:13*//*14:*/
00581 #line 440 "tie.w"
00582 
00583 for(i= first_text_char;i<=last_text_char;xord[i++]= 32)do_nothing;
00584 for(i= 1;i<=126;i++)xord[xchr[i]]= i;
00585 
00586 
00587 
00588 
00589 
00590 /*:14*/
00591 #line 1239 "tie.w"
00592 
00593 }
00594 print_ln(banner);
00595 print_ln(copyright);
00596 actual_input= 0;
00597 out_mode= normal;
00598 /*56:*/
00599 #line 1177 "tie.w"
00600 
00601 {int act_arg;
00602 if(argc<5||argc>max_file_index+4-1)usage();
00603 no_ch= -1;
00604 for(act_arg= 1;act_arg<argc;act_arg++){
00605 if(argv[act_arg][0]=='-')/*57:*/
00606 #line 1195 "tie.w"
00607 
00608 if(prod_chf!=unknown)usage();
00609 else
00610 switch(argv[act_arg][1]){
00611 case'c':
00612 case'C':prod_chf= chf;break;
00613 case'm':
00614 case'M':prod_chf= master;break;
00615 default:usage();
00616 }
00617 
00618 
00619 /*:57*/
00620 #line 1182 "tie.w"
00621 
00622 else/*58:*/
00623 #line 1211 "tie.w"
00624 
00625 {if(no_ch==(-1)){
00626 out_name= argv[act_arg];
00627 }else{register input_description*inp_desc;
00628 inp_desc= (input_description*)
00629 malloc(sizeof(input_description));
00630 if(inp_desc==NULL)
00631 fatal_error("! No memory for descriptor");
00632 
00633 inp_desc->mode= search;
00634 inp_desc->line= 0;
00635 inp_desc->type_of_file= chf;
00636 inp_desc->limit= 0;
00637 inp_desc->name_of_file= argv[act_arg];
00638 input_organization[no_ch]= inp_desc;
00639 }
00640 incr(no_ch);
00641 }
00642 
00643 
00644 /*:58*/
00645 #line 1183 "tie.w"
00646 
00647 }
00648 if(no_ch<=0||prod_chf==unknown)usage();
00649 }
00650 
00651 
00652 /*:56*/
00653 #line 1245 "tie.w"
00654 
00655 /*34:*/
00656 #line 788 "tie.w"
00657 
00658 {
00659 out_file= fopen(out_name,"w");
00660 if(out_file==NULL){
00661 fatal_error("! Could not open/create output file");
00662 
00663 }
00664 }
00665 
00666 
00667 /*:34*/
00668 #line 1246 "tie.w"
00669 
00670 /*36:*/
00671 #line 809 "tie.w"
00672 
00673 {input_organization[0]->the_file= 
00674 fopen(input_organization[0]->name_of_file,"r");
00675 if(input_organization[0]->the_file==NULL)
00676 fatal_error("! Could not open master file");
00677 
00678 print2("(%s)",input_organization[0]->name_of_file);
00679 term_new_line;
00680 input_organization[0]->type_of_file= master;
00681 get_line(0);
00682 }
00683 
00684 /*:36*/
00685 #line 1247 "tie.w"
00686 
00687 /*37:*/
00688 #line 825 "tie.w"
00689 
00690 {file_index i;
00691 i= 1;
00692 while(i<no_ch){
00693 input_organization[i]->the_file= 
00694 fopen(input_organization[i]->name_of_file,"r");
00695 if(input_organization[i]->the_file==NULL)
00696 fatal_error("!Could not open change file");
00697 
00698 print2("(%s)",input_organization[i]->name_of_file);
00699 term_new_line;
00700 init_change_file(i,true);
00701 incr(i);
00702 }
00703 }
00704 
00705 
00706 
00707 
00708 
00709 /*:37*/
00710 #line 1248 "tie.w"
00711 
00712 /*53:*/
00713 #line 1128 "tie.w"
00714 
00715 actual_input= 0;
00716 input_has_ended= false;
00717 while(input_has_ended==false||actual_input!=0)
00718 /*45:*/
00719 #line 970 "tie.w"
00720 
00721 {file_index test_file;
00722 /*46:*/
00723 #line 985 "tie.w"
00724 
00725 {register input_description*inp_desc;
00726 while(actual_input>0&&e_of_ch_module(actual_input)){
00727 inp_desc= input_organization[actual_input];
00728 if(inp_desc->type_of_file==master){
00729 
00730 fatal_error("! This can't happen: change file is master file");
00731 
00732 }
00733 inp_desc->mode= search;
00734 init_change_file(actual_input,true);
00735 while((input_organization[actual_input]->mode!=reading
00736 &&actual_input>0))decr(actual_input);
00737 }
00738 }
00739 
00740 
00741 /*:46*/
00742 #line 972 "tie.w"
00743 
00744 if(input_has_ended&&actual_input==0)break;
00745 /*47:*/
00746 #line 1009 "tie.w"
00747 
00748 test_input= none;
00749 test_file= actual_input;
00750 while(test_input==none&&test_file<no_ch-1){
00751 incr(test_file);
00752 switch(input_organization[test_file]->mode){
00753 case search:if(lines_dont_match(actual_input,test_file)==false){
00754 input_organization[test_file]->mode= test;
00755 test_input= test_file;
00756 }
00757 break;
00758 case test:if(lines_dont_match(actual_input,test_file)==true){
00759 
00760 input_organization[test_file]->mode= search;
00761 err_print("! Sections do not match")(actual_input);
00762 
00763 err_loc(test_file);
00764 init_change_file(test_file,false);
00765 }else test_input= test_file;
00766 break;
00767 case reading:do_nothing;
00768 break;
00769 case ignore:do_nothing;
00770 break;
00771 }
00772 }
00773 
00774 
00775 /*:47*/
00776 #line 974 "tie.w"
00777 
00778 /*48:*/
00779 #line 1043 "tie.w"
00780 
00781 if(prod_chf==chf){
00782 loop{
00783 /*49:*/
00784 #line 1057 "tie.w"
00785 
00786 if(out_mode==normal){
00787 if(test_input!=none){
00788 fputc(map_xchr(64),out_file);fputc(map_xchr(120),out_file);
00789 new_line(out_file);
00790 out_mode= pre;
00791 }else break;
00792 }
00793 
00794 
00795 /*:49*/
00796 #line 1046 "tie.w"
00797 
00798 /*50:*/
00799 #line 1071 "tie.w"
00800 
00801 
00802 if(out_mode==pre){
00803 if(test_input==none){
00804 fputc(map_xchr(64),out_file);fputc(map_xchr(121),out_file);
00805 new_line(out_file);
00806 out_mode= post;
00807 }else{
00808 if(input_organization[actual_input]->type_of_file==master)
00809 put_line(actual_input);
00810 break;
00811 }
00812 }
00813 
00814 
00815 /*:50*/
00816 #line 1047 "tie.w"
00817 
00818 /*51:*/
00819 #line 1092 "tie.w"
00820 
00821 if(out_mode==post){
00822 if(input_organization[actual_input]->type_of_file==chf){
00823 if(test_input==none)put_line(actual_input);
00824 break;
00825 }else{
00826 fputc(map_xchr(64),out_file);fputc(map_xchr(122),out_file);
00827 new_line(out_file);
00828 new_line(out_file);
00829 out_mode= normal;
00830 }
00831 }
00832 
00833 
00834 /*:51*/
00835 #line 1048 "tie.w"
00836 
00837 }
00838 }else
00839 if(test_input==none)put_line(actual_input);
00840 
00841 
00842 /*:48*/
00843 #line 975 "tie.w"
00844 
00845 /*52:*/
00846 #line 1109 "tie.w"
00847 
00848 get_line(actual_input);
00849 if(test_input!=none){
00850 get_line(test_input);
00851 if(e_of_ch_preamble(test_input)==true){
00852 get_line(test_input);
00853 input_organization[test_input]->mode= reading;
00854 actual_input= test_input;
00855 test_input= none;
00856 }
00857 }
00858 
00859 
00860 /*:52*/
00861 #line 976 "tie.w"
00862 
00863 }
00864 
00865 
00866 /*:45*/
00867 #line 1132 "tie.w"
00868 
00869 if(out_mode==post){
00870 fputc(map_xchr(64),out_file);fputc(map_xchr(122),out_file);
00871 new_line(out_file);
00872 }
00873 
00874 
00875 /*:53*/
00876 #line 1249 "tie.w"
00877 
00878 /*54:*/
00879 #line 1143 "tie.w"
00880 
00881 {file_index i;
00882 for(i= 1;i<no_ch;i++){
00883 if(input_organization[i]->mode!=ignore)
00884 err_print("! Change file entry did not match")(i);
00885 
00886 }
00887 }
00888 
00889 
00890 /*:54*/
00891 #line 1250 "tie.w"
00892 
00893 /*60:*/
00894 #line 1261 "tie.w"
00895 
00896 {string msg;
00897 switch(history){
00898 case spotless:msg= "No errors were found";break;
00899 case troublesome:msg= "Pardon me, but I think I spotted something wrong.";
00900 break;
00901 case fatal:msg= "That was a fatal error, my friend";break;
00902 }
00903 print2_nl("(%s.)",msg);term_new_line;
00904 exit(history==spotless?0:1);
00905 }
00906 
00907 
00908 
00909 
00910 
00911 /*:60*/
00912 #line 1251 "tie.w"
00913 
00914 }
00915 
00916 /*:59*/
00917 #line 119 "tie.w"
00918 
00919 
00920 /*:2*/