summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c/cwebboot.cin
diff options
context:
space:
mode:
authorAndreas Scherer <andreas_tex@freenet.de>2021-02-24 18:19:47 +0000
committerAndreas Scherer <andreas_tex@freenet.de>2021-02-24 18:19:47 +0000
commit5f6231423ff11a042181be707faa0db6012b8e35 (patch)
tree1aa670b8921584ddbc3c972cb6016d4bbb670606 /Build/source/texk/web2c/cwebboot.cin
parent180bb00c12d352e3d1c374a1587d4dc898300c5f (diff)
[CWEB] Code review.
Compactify single function declarations. git-svn-id: svn://tug.org/texlive/trunk@57874 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/cwebboot.cin')
-rw-r--r--Build/source/texk/web2c/cwebboot.cin302
1 files changed, 149 insertions, 153 deletions
diff --git a/Build/source/texk/web2c/cwebboot.cin b/Build/source/texk/web2c/cwebboot.cin
index f455693f118..150c303a346 100644
--- a/Build/source/texk/web2c/cwebboot.cin
+++ b/Build/source/texk/web2c/cwebboot.cin
@@ -290,10 +290,11 @@ cweb program;
/*:18*//*19:*/
#line 92 "cwebdir/common.w"
+
int phase;
/*:19*//*21:*/
-#line 129 "cwebdir/common.w"
+#line 130 "cwebdir/common.w"
char section_text[longest_name+1];
char*section_text_end= section_text+longest_name;
@@ -301,7 +302,7 @@ char*id_first;
char*id_loc;
/*:21*//*22:*/
-#line 149 "cwebdir/common.w"
+#line 150 "cwebdir/common.w"
char buffer[long_buf_size];
char*buffer_end= buffer+buf_size-2;
@@ -332,7 +333,7 @@ static char change_buffer[buf_size];
static char*change_limit;
/*:26*//*37:*/
-#line 401 "cwebdir/common.w"
+#line 399 "cwebdir/common.w"
sixteen_bits section_count;
boolean changed_section[max_sections];
@@ -341,7 +342,7 @@ boolean change_pending;
boolean print_where= false;
/*:37*//*43:*/
-#line 598 "cwebdir/common.w"
+#line 596 "cwebdir/common.w"
char byte_mem[max_bytes];
char*byte_mem_end= byte_mem+max_bytes-1;
@@ -349,25 +350,25 @@ name_info name_dir[max_names];
name_pointer name_dir_end= name_dir+max_names-1;
/*:43*//*44:*/
-#line 609 "cwebdir/common.w"
+#line 607 "cwebdir/common.w"
char*byte_ptr;
name_pointer name_ptr;
/*:44*//*46:*/
-#line 629 "cwebdir/common.w"
+#line 627 "cwebdir/common.w"
name_pointer hash[hash_size];
hash_pointer hash_end= hash+hash_size-1;
hash_pointer h;
/*:46*//*65:*/
-#line 1017 "cwebdir/common.w"
+#line 1014 "cwebdir/common.w"
int history= spotless;
/*:65*//*73:*/
-#line 1138 "cwebdir/common.w"
+#line 1135 "cwebdir/common.w"
int argc;
char**argv;
@@ -377,11 +378,11 @@ char idx_file_name[max_file_name_length];
#line 431 "cwebdir/comm-w2c.ch"
char scn_file_name[max_file_name_length];
char check_file_name[max_file_name_length];
-#line 1145 "cwebdir/common.w"
+#line 1142 "cwebdir/common.w"
boolean flags[128];
/*:73*//*83:*/
-#line 1286 "cwebdir/common.w"
+#line 1282 "cwebdir/common.w"
FILE*C_file;
FILE*tex_file;
@@ -392,7 +393,7 @@ FILE*check_file;
#line 576 "cwebdir/comm-w2c.ch"
FILE*active_file;
char*found_filename;
-#line 1292 "cwebdir/common.w"
+#line 1288 "cwebdir/common.w"
#line 593 "cwebdir/comm-w2c.ch"
/*:83*//*86:*/
@@ -449,39 +450,35 @@ extern void common_init(void);
extern void print_stats(void);
extern void cb_show_banner(void);
-/*:15*//*23:*/
-#line 159 "cwebdir/common.w"
-
+/*:15*//*24:*/
+#line 180 "cwebdir/common.w"
static boolean input_ln(FILE*);
-/*:23*//*27:*/
-#line 231 "cwebdir/common.w"
-
+/*:24*//*28:*/
+#line 241 "cwebdir/common.w"
static void prime_the_change_buffer(void);
-/*:27*//*32:*/
-#line 303 "cwebdir/common.w"
-
+/*:28*//*33:*/
+#line 340 "cwebdir/common.w"
static void check_change(void);
-/*:32*//*55:*/
-#line 776 "cwebdir/common.w"
+/*:33*//*55:*/
+#line 774 "cwebdir/common.w"
static int web_strcmp(char*,int,char*,int);
static name_pointer add_section_name(name_pointer,int,char*,char*,int);
static void extend_section_name(name_pointer,char*,char*,int);
-/*:55*//*63:*/
-#line 972 "cwebdir/common.w"
-
+/*:55*//*64:*/
+#line 1002 "cwebdir/common.w"
static int section_name_cmp(char**,int,name_pointer);
-/*:63*//*75:*/
-#line 1170 "cwebdir/common.w"
-
+/*:64*//*76:*/
+#line 1197 "cwebdir/common.w"
static void scan_args(void);
-/*:75*//*96:*/
+#line 496 "cwebdir/comm-w2c.ch"
+/*:76*//*96:*/
#line 808 "cwebdir/comm-w2c.ch"
static void cb_usage(const_string str);
@@ -492,14 +489,14 @@ static void cb_usagehelp(const_string*message,const_string bug_email);
/*:1*//*20:*/
-#line 98 "cwebdir/common.w"
+#line 99 "cwebdir/common.w"
void
common_init(void)
{
#line 78 "cwebdir/comm-w2c.ch"
/*45:*/
-#line 613 "cwebdir/common.w"
+#line 611 "cwebdir/common.w"
name_dir->byte_start= byte_ptr= byte_mem;
name_ptr= name_dir+1;
@@ -507,7 +504,7 @@ name_ptr->byte_start= byte_mem;
root= NULL;
/*:45*//*47:*/
-#line 636 "cwebdir/common.w"
+#line 634 "cwebdir/common.w"
for(h= hash;h<=hash_end;*h++= NULL);
@@ -543,18 +540,18 @@ textdomain("cweb");
#line 85 "cwebdir/comm-w2c.ch"
/*74:*/
-#line 1151 "cwebdir/common.w"
+#line 1148 "cwebdir/common.w"
#line 438 "cwebdir/comm-w2c.ch"
make_xrefs= true;
temporary_output= true;
-#line 1153 "cwebdir/common.w"
+#line 1150 "cwebdir/common.w"
show_stats= false;
/*:74*/
#line 86 "cwebdir/comm-w2c.ch"
-#line 104 "cwebdir/common.w"
+#line 105 "cwebdir/common.w"
/*84:*/
#line 593 "cwebdir/comm-w2c.ch"
@@ -587,16 +584,16 @@ else strcpy(dot_pos,".wtp");
if((tex_file= fopen(check_file_name,"wb"))==NULL)
fatal(_("! Cannot open output file "),check_file_name);
}
-#line 1304 "cwebdir/common.w"
+#line 1300 "cwebdir/common.w"
#line 628 "cwebdir/comm-w2c.ch"
/*:84*/
-#line 104 "cwebdir/common.w"
+#line 105 "cwebdir/common.w"
}
-/*:20*//*24:*/
-#line 162 "cwebdir/common.w"
+/*:20*//*23:*/
+#line 160 "cwebdir/common.w"
static boolean input_ln(
FILE*fp)
@@ -608,12 +605,12 @@ limit= k= buffer;
while(k<=buffer_end&&(c= getc(fp))!=EOF&&c!='\n')
#line 92 "cwebdir/comm-w2c.ch"
if((*(k++)= c)!=' '&&c!='\r')limit= k;
-#line 172 "cwebdir/common.w"
+#line 170 "cwebdir/common.w"
if(k> buffer_end)
if((c= getc(fp))!=EOF&&c!='\n'){
#line 98 "cwebdir/comm-w2c.ch"
ungetc(c,fp);loc= buffer;err_print(_("! Input line too long"));
-#line 175 "cwebdir/common.w"
+#line 173 "cwebdir/common.w"
}
if(c==EOF&&limit==buffer)return false;
@@ -621,15 +618,15 @@ if(c==EOF&&limit==buffer)return false;
return true;
}
-/*:24*//*28:*/
-#line 234 "cwebdir/common.w"
+/*:23*//*27:*/
+#line 231 "cwebdir/common.w"
static void
prime_the_change_buffer(void)
{
change_limit= change_buffer;
/*29:*/
-#line 248 "cwebdir/common.w"
+#line 247 "cwebdir/common.w"
while(true){
change_line++;
@@ -642,33 +639,33 @@ if(buffer[1]=='y'||buffer[1]=='z'||buffer[1]=='i'){
loc= buffer+2;
#line 109 "cwebdir/comm-w2c.ch"
err_print(_("! Missing @x in change file"));
-#line 259 "cwebdir/common.w"
+#line 258 "cwebdir/common.w"
}
}
/*:29*/
-#line 239 "cwebdir/common.w"
+#line 236 "cwebdir/common.w"
/*30:*/
-#line 265 "cwebdir/common.w"
+#line 264 "cwebdir/common.w"
do{
change_line++;
if(!input_ln(change_file)){
#line 115 "cwebdir/comm-w2c.ch"
err_print(_("! Change file ended after @x"));
-#line 270 "cwebdir/common.w"
+#line 269 "cwebdir/common.w"
return;
}
}while(limit==buffer);
/*:30*/
-#line 240 "cwebdir/common.w"
+#line 237 "cwebdir/common.w"
/*31:*/
-#line 275 "cwebdir/common.w"
+#line 274 "cwebdir/common.w"
{
change_limit= change_buffer+(ptrdiff_t)(limit-buffer);
@@ -676,12 +673,12 @@ strncpy(change_buffer,buffer,(size_t)(limit-buffer+1));
}
/*:31*/
-#line 241 "cwebdir/common.w"
+#line 238 "cwebdir/common.w"
}
-/*:28*//*33:*/
-#line 306 "cwebdir/common.w"
+/*:27*//*32:*/
+#line 302 "cwebdir/common.w"
static void
check_change(void)
@@ -698,7 +695,7 @@ changing= true;print_where= true;change_line++;
if(!input_ln(change_file)){
#line 121 "cwebdir/comm-w2c.ch"
err_print(_("! Change file ended before @y"));
-#line 321 "cwebdir/common.w"
+#line 317 "cwebdir/common.w"
change_limit= change_buffer;changing= false;
return;
@@ -706,12 +703,12 @@ return;
if(limit> buffer+1&&buffer[0]=='@'){
char xyz_code= xisupper(buffer[1])?tolower((eight_bits)buffer[1]):buffer[1];
/*34:*/
-#line 344 "cwebdir/common.w"
+#line 342 "cwebdir/common.w"
if(xyz_code=='x'||xyz_code=='z'){
#line 133 "cwebdir/comm-w2c.ch"
loc= buffer+2;err_print(_("! Where is the matching @y?"));
-#line 347 "cwebdir/common.w"
+#line 345 "cwebdir/common.w"
}
else if(xyz_code=='y'){
@@ -720,7 +717,7 @@ loc= buffer+2;
printf("\n! Hmm... %d ",n);
#line 139 "cwebdir/comm-w2c.ch"
err_print(_("of the preceding lines failed to match"));
-#line 354 "cwebdir/common.w"
+#line 352 "cwebdir/common.w"
}
change_depth= include_depth;
@@ -728,11 +725,11 @@ return;
}
/*:34*/
-#line 328 "cwebdir/common.w"
+#line 324 "cwebdir/common.w"
}
/*31:*/
-#line 275 "cwebdir/common.w"
+#line 274 "cwebdir/common.w"
{
change_limit= change_buffer+(ptrdiff_t)(limit-buffer);
@@ -740,14 +737,14 @@ strncpy(change_buffer,buffer,(size_t)(limit-buffer+1));
}
/*:31*/
-#line 330 "cwebdir/common.w"
+#line 326 "cwebdir/common.w"
changing= false;cur_line++;
while(!input_ln(cur_file)){
if(include_depth==0){
#line 127 "cwebdir/comm-w2c.ch"
err_print(_("! CWEB file ended during a change"));
-#line 335 "cwebdir/common.w"
+#line 331 "cwebdir/common.w"
input_has_ended= true;return;
}
@@ -757,15 +754,15 @@ if(lines_dont_match)n++;
}
}
-/*:33*//*35:*/
-#line 364 "cwebdir/common.w"
+/*:32*//*35:*/
+#line 362 "cwebdir/common.w"
void
reset_input(void)
{
limit= buffer;loc= buffer+1;buffer[0]= ' ';
/*36:*/
-#line 379 "cwebdir/common.w"
+#line 377 "cwebdir/common.w"
#line 149 "cwebdir/comm-w2c.ch"
if((found_filename= kpse_find_cweb(web_file_name))==NULL||
@@ -778,7 +775,7 @@ strcpy(web_file_name,found_filename+
((strncmp(found_filename,"./",2)==0)?2:0));
free(found_filename);
}else fatal(_("! Filename too long\n"),found_filename);
-#line 385 "cwebdir/common.w"
+#line 383 "cwebdir/common.w"
web_file_open= true;
@@ -793,10 +790,10 @@ strcpy(change_file_name,found_filename+
((strncmp(found_filename,"./",2)==0)?2:0));
free(found_filename);
}else fatal(_("! Filename too long\n"),found_filename);
-#line 390 "cwebdir/common.w"
+#line 388 "cwebdir/common.w"
/*:36*/
-#line 369 "cwebdir/common.w"
+#line 367 "cwebdir/common.w"
include_depth= 0;cur_line= 0;change_line= 0;
change_depth= include_depth;
@@ -805,20 +802,20 @@ limit= buffer;loc= buffer+1;buffer[0]= ' ';input_has_ended= false;
}
/*:35*//*38:*/
-#line 408 "cwebdir/common.w"
+#line 406 "cwebdir/common.w"
boolean get_line(void)
{
restart:
if(changing&&include_depth==change_depth)
/*41:*/
-#line 516 "cwebdir/common.w"
+#line 514 "cwebdir/common.w"
{
change_line++;
if(!input_ln(change_file)){
#line 274 "cwebdir/comm-w2c.ch"
err_print(_("! Change file ended without @z"));
-#line 520 "cwebdir/common.w"
+#line 518 "cwebdir/common.w"
buffer[0]= '@';buffer[1]= 'z';limit= buffer+2;
}
@@ -836,7 +833,7 @@ if(buffer[1]=='x'||buffer[1]=='y'){
loc= buffer+2;
#line 280 "cwebdir/comm-w2c.ch"
err_print(_("! Where is the matching @z?"));
-#line 536 "cwebdir/common.w"
+#line 534 "cwebdir/common.w"
}
else if(buffer[1]=='z'){
@@ -847,11 +844,11 @@ prime_the_change_buffer();changing= !changing;print_where= true;
}
/*:41*/
-#line 413 "cwebdir/common.w"
+#line 411 "cwebdir/common.w"
if(!changing||include_depth> change_depth){
/*40:*/
-#line 499 "cwebdir/common.w"
+#line 497 "cwebdir/common.w"
{
cur_line++;
while(!input_ln(cur_file)){
@@ -870,7 +867,7 @@ if(change_limit> change_buffer)check_change();
}
/*:40*/
-#line 415 "cwebdir/common.w"
+#line 413 "cwebdir/common.w"
if(changing&&include_depth==change_depth)goto restart;
}
@@ -882,25 +879,25 @@ while(*loc==' '||*loc=='\t')loc++;
if(loc>=limit){
#line 180 "cwebdir/comm-w2c.ch"
err_print(_("! Include file name not given"));
-#line 425 "cwebdir/common.w"
+#line 423 "cwebdir/common.w"
goto restart;
}
if(include_depth>=max_include_depth-1){
#line 186 "cwebdir/comm-w2c.ch"
err_print(_("! Too many nested includes"));
-#line 430 "cwebdir/common.w"
+#line 428 "cwebdir/common.w"
goto restart;
}
include_depth++;
/*39:*/
-#line 453 "cwebdir/common.w"
+#line 451 "cwebdir/common.w"
{
#line 223 "cwebdir/comm-w2c.ch"
char*cur_file_name_end= cur_file_name+max_file_name_length-1;
char*k= cur_file_name;
-#line 458 "cwebdir/common.w"
+#line 456 "cwebdir/common.w"
if(*loc=='"'){
loc++;
@@ -921,17 +918,17 @@ strcpy(cur_file_name,found_filename+
((strncmp(found_filename,"./",2)==0)?2:0));
free(found_filename);
}else fatal(_("! Filename too long\n"),found_filename);
-#line 469 "cwebdir/common.w"
+#line 467 "cwebdir/common.w"
cur_line= 0;print_where= true;
goto restart;
}
#line 268 "cwebdir/comm-w2c.ch"
include_depth--;err_print(_("! Cannot open include file"));goto restart;
-#line 497 "cwebdir/common.w"
+#line 495 "cwebdir/common.w"
}
/*:39*/
-#line 434 "cwebdir/common.w"
+#line 432 "cwebdir/common.w"
}
return true;
@@ -939,7 +936,7 @@ return true;
#line 201 "cwebdir/comm-w2c.ch"
/*:38*//*42:*/
-#line 548 "cwebdir/common.w"
+#line 546 "cwebdir/common.w"
void
check_complete(void){
@@ -949,13 +946,13 @@ limit= buffer+(ptrdiff_t)(change_limit-change_buffer);
changing= true;change_depth= include_depth;loc= buffer;
#line 286 "cwebdir/comm-w2c.ch"
err_print(_("! Change file entry did not match"));
-#line 556 "cwebdir/common.w"
+#line 554 "cwebdir/common.w"
}
}
/*:42*//*48:*/
-#line 641 "cwebdir/common.w"
+#line 639 "cwebdir/common.w"
name_pointer
id_lookup(
@@ -970,17 +967,17 @@ name_pointer p;
if(last==NULL)for(last= first;*last!='\0';last++);
l= (int)(last-first);
/*49:*/
-#line 664 "cwebdir/common.w"
+#line 662 "cwebdir/common.w"
h= (eight_bits)*i;
while(++i<last)h= (h+h+(int)((eight_bits)*i))%hash_size;
/*:49*/
-#line 654 "cwebdir/common.w"
+#line 652 "cwebdir/common.w"
/*50:*/
-#line 672 "cwebdir/common.w"
+#line 670 "cwebdir/common.w"
p= hash[h];
while(p&&!names_match(p,first,l,t))p= p->link;
@@ -990,28 +987,28 @@ p->link= hash[h];hash[h]= p;
}
/*:50*/
-#line 655 "cwebdir/common.w"
+#line 653 "cwebdir/common.w"
if(p==name_ptr)/*51:*/
-#line 683 "cwebdir/common.w"
+#line 681 "cwebdir/common.w"
{
#line 293 "cwebdir/comm-w2c.ch"
if(byte_ptr+l> byte_mem_end)overflow(_("byte memory"));
if(name_ptr>=name_dir_end)overflow(_("name"));
-#line 686 "cwebdir/common.w"
+#line 684 "cwebdir/common.w"
strncpy(byte_ptr,first,l);
(++name_ptr)->byte_start= byte_ptr+= l;
init_p(p,t);
}
/*:51*/
-#line 656 "cwebdir/common.w"
+#line 654 "cwebdir/common.w"
return p;
}
/*:48*//*52:*/
-#line 715 "cwebdir/common.w"
+#line 713 "cwebdir/common.w"
void
print_section_name(
@@ -1032,7 +1029,7 @@ if(q)term_write("...",3);
}
/*:52*//*53:*/
-#line 734 "cwebdir/common.w"
+#line 732 "cwebdir/common.w"
void
sprint_section_name(
@@ -1055,7 +1052,7 @@ s= p->byte_start;
}
/*:53*//*54:*/
-#line 755 "cwebdir/common.w"
+#line 753 "cwebdir/common.w"
void
print_prefix_name(
@@ -1068,7 +1065,7 @@ if(s+l<(p+1)->byte_start)term_write("...",3);
}
/*:54*//*56:*/
-#line 781 "cwebdir/common.w"
+#line 779 "cwebdir/common.w"
static int web_strcmp(
char*j,
@@ -1086,7 +1083,7 @@ else return greater;
}
/*:56*//*57:*/
-#line 810 "cwebdir/common.w"
+#line 808 "cwebdir/common.w"
static name_pointer
add_section_name(
@@ -1102,7 +1099,7 @@ int name_len= (int)(last-first)+ispref;
#line 301 "cwebdir/comm-w2c.ch"
if(s+name_len> byte_mem_end)overflow(_("byte memory"));
if(name_ptr+1>=name_dir_end)overflow(_("name"));
-#line 824 "cwebdir/common.w"
+#line 822 "cwebdir/common.w"
(++name_ptr)->byte_start= byte_ptr= s+name_len;
if(ispref){
*(byte_ptr-1)= ' ';
@@ -1119,7 +1116,7 @@ return par==NULL?(root= p):c==less?(par->llink= p):(par->rlink= p);
}
/*:57*//*58:*/
-#line 839 "cwebdir/common.w"
+#line 837 "cwebdir/common.w"
static void
extend_section_name(
@@ -1133,21 +1130,21 @@ name_pointer q= p+1;
int name_len= (int)(last-first)+ispref;
#line 308 "cwebdir/comm-w2c.ch"
if(name_ptr>=name_dir_end)overflow(_("name"));
-#line 851 "cwebdir/common.w"
+#line 849 "cwebdir/common.w"
while(q->link!=name_dir)q= q->link;
q->link= name_ptr;
s= name_ptr->byte_start;
name_ptr->link= name_dir;
#line 314 "cwebdir/comm-w2c.ch"
if(s+name_len> byte_mem_end)overflow(_("byte memory"));
-#line 856 "cwebdir/common.w"
+#line 854 "cwebdir/common.w"
(++name_ptr)->byte_start= byte_ptr= s+name_len;
strncpy(s,first,name_len);
if(ispref)*(byte_ptr-1)= ' ';
}
/*:58*//*59:*/
-#line 867 "cwebdir/common.w"
+#line 865 "cwebdir/common.w"
name_pointer
section_lookup(
@@ -1162,7 +1159,7 @@ name_pointer par= NULL;
int name_len= (int)(last-first)+1;
/*60:*/
-#line 891 "cwebdir/common.w"
+#line 889 "cwebdir/common.w"
while(p){
c= web_strcmp(first,name_len,first_chunk(p),prefix_length(p));
@@ -1174,12 +1171,12 @@ p= (c==less?p->llink:p->rlink);
if(r!=NULL){
#line 320 "cwebdir/comm-w2c.ch"
fputs(_("\n! Ambiguous prefix: matches <"),stdout);
-#line 901 "cwebdir/common.w"
+#line 899 "cwebdir/common.w"
print_prefix_name(p);
#line 326 "cwebdir/comm-w2c.ch"
fputs(_(">\n and <"),stdout);
-#line 904 "cwebdir/common.w"
+#line 902 "cwebdir/common.w"
print_prefix_name(r);
err_print(">");
return name_dir;
@@ -1193,19 +1190,19 @@ p= q,q= NULL;
}
/*:60*/
-#line 881 "cwebdir/common.w"
+#line 879 "cwebdir/common.w"
/*61:*/
-#line 916 "cwebdir/common.w"
+#line 914 "cwebdir/common.w"
if(r==NULL)
return add_section_name(par,c,first,last+1,ispref);
/*:61*/
-#line 882 "cwebdir/common.w"
+#line 880 "cwebdir/common.w"
/*62:*/
-#line 924 "cwebdir/common.w"
+#line 922 "cwebdir/common.w"
switch(section_name_cmp(&first,name_len,r)){
@@ -1213,7 +1210,7 @@ case prefix:
if(!ispref){
#line 332 "cwebdir/comm-w2c.ch"
fputs(_("\n! New name is a prefix of <"),stdout);
-#line 930 "cwebdir/common.w"
+#line 928 "cwebdir/common.w"
print_section_name(r);
err_print(">");
@@ -1227,7 +1224,7 @@ return r;
case bad_extension:
#line 338 "cwebdir/comm-w2c.ch"
fputs(_("\n! New name extends <"),stdout);
-#line 942 "cwebdir/common.w"
+#line 940 "cwebdir/common.w"
print_section_name(r);
err_print(">");
@@ -1235,24 +1232,24 @@ return r;
default:
#line 344 "cwebdir/comm-w2c.ch"
fputs(_("\n! Section name incompatible with <"),stdout);
-#line 948 "cwebdir/common.w"
+#line 946 "cwebdir/common.w"
print_prefix_name(r);
#line 350 "cwebdir/comm-w2c.ch"
fputs(_(">,\n which abbreviates <"),stdout);
-#line 951 "cwebdir/common.w"
+#line 949 "cwebdir/common.w"
print_section_name(r);
err_print(">");
return r;
}
/*:62*/
-#line 883 "cwebdir/common.w"
+#line 881 "cwebdir/common.w"
}
-/*:59*//*64:*/
-#line 975 "cwebdir/common.w"
+/*:59*//*63:*/
+#line 970 "cwebdir/common.w"
static int section_name_cmp(
char**pfirst,
@@ -1285,8 +1282,8 @@ default:return c;
}
}
-/*:64*//*66:*/
-#line 1027 "cwebdir/common.w"
+/*:63*//*66:*/
+#line 1024 "cwebdir/common.w"
void
err_print(
@@ -1295,14 +1292,14 @@ const char*s)
char*k,*l;
printf(*s=='!'?"\n%s":"%s",s);
if(web_file_open)/*67:*/
-#line 1047 "cwebdir/common.w"
+#line 1044 "cwebdir/common.w"
{if(changing&&include_depth==change_depth)
#line 358 "cwebdir/comm-w2c.ch"
printf(_(". (l. %d of change file)\n"),change_line);
else if(include_depth==0)printf(_(". (l. %d)\n"),cur_line);
else printf(_(". (l. %d of include file %s)\n"),cur_line,cur_file_name);
-#line 1052 "cwebdir/common.w"
+#line 1049 "cwebdir/common.w"
l= (loc>=limit?limit:loc);
if(l> buffer){
for(k= buffer;k<l;k++)
@@ -1317,13 +1314,13 @@ putchar(' ');
}
/*:67*/
-#line 1034 "cwebdir/common.w"
+#line 1031 "cwebdir/common.w"
update_terminal;mark_error;
}
/*:66*//*68:*/
-#line 1079 "cwebdir/common.w"
+#line 1076 "cwebdir/common.w"
int wrap_up(void){
if(show_progress)new_line;
@@ -1331,7 +1328,7 @@ if(show_stats)
print_stats();
#line 388 "cwebdir/comm-w2c.ch"
/*69:*/
-#line 1089 "cwebdir/common.w"
+#line 1086 "cwebdir/common.w"
switch(history){
#line 412 "cwebdir/comm-w2c.ch"
@@ -1343,7 +1340,7 @@ case error_message:
puts(_("(Pardon me, but I think I spotted something wrong.)"));break;
case fatal_message:
puts(_("(That was a fatal error, my friend.)"));
-#line 1097 "cwebdir/common.w"
+#line 1094 "cwebdir/common.w"
}
/*:69*/
@@ -1368,11 +1365,11 @@ case error_message:return RETURN_ERROR;
case fatal_message:return RETURN_FAIL;
default:return RETURN_OK;
}
-#line 1087 "cwebdir/common.w"
+#line 1084 "cwebdir/common.w"
}
/*:68*//*70:*/
-#line 1105 "cwebdir/common.w"
+#line 1102 "cwebdir/common.w"
void
fatal(
const char*s,const char*t)
@@ -1383,19 +1380,19 @@ history= fatal_message;exit(wrap_up());
}
/*:70*//*71:*/
-#line 1116 "cwebdir/common.w"
+#line 1113 "cwebdir/common.w"
void
overflow(
const char*t)
{
#line 425 "cwebdir/comm-w2c.ch"
printf(_("\n! Sorry, %s capacity exceeded"),t);fatal("","");
-#line 1121 "cwebdir/common.w"
+#line 1118 "cwebdir/common.w"
}
-/*:71*//*76:*/
-#line 1173 "cwebdir/common.w"
+/*:71*//*75:*/
+#line 1167 "cwebdir/common.w"
static void
scan_args(void)
@@ -1418,7 +1415,7 @@ change_file_name[max_file_name_length-2]= '\0';
strcpy(change_file_name,"/dev/null");
#endif
-#line 1184 "cwebdir/common.w"
+#line 1178 "cwebdir/common.w"
while(--argc> 0){
if((**(++argv)=='-'||**argv=='+')&&*(*argv+1))/*80:*/
#line 510 "cwebdir/comm-w2c.ch"
@@ -1468,7 +1465,7 @@ if(sscanf(++dot_pos,"%u",&kpathsea_debug)!=1)/*81:*/
cb_usage(program==ctangle?"ctangle":program==cweave?"cweave":"ctwill");
-#line 1279 "cwebdir/common.w"
+#line 1275 "cwebdir/common.w"
#line 563 "cwebdir/comm-w2c.ch"
/*:81*/
@@ -1481,13 +1478,13 @@ if(*dot_pos=='l'){
use_language= ++dot_pos;
break;
}else
-#line 1265 "cwebdir/common.w"
+#line 1261 "cwebdir/common.w"
flags[(eight_bits)*dot_pos]= flag_change;
}
#line 555 "cwebdir/comm-w2c.ch"
/*:80*/
-#line 1185 "cwebdir/common.w"
+#line 1179 "cwebdir/common.w"
else{
s= name_pos= *argv;dot_pos= NULL;
@@ -1499,20 +1496,20 @@ dot_pos= NULL,name_pos= ++s;
else s++;
}
-#line 1193 "cwebdir/common.w"
+#line 1187 "cwebdir/common.w"
if(!found_web)/*77:*/
-#line 1210 "cwebdir/common.w"
+#line 1206 "cwebdir/common.w"
{
if(s-*argv> max_file_name_length-5)
/*82:*/
#line 563 "cwebdir/comm-w2c.ch"
fatal(_("! Filename too long\n"),*argv);
-#line 1281 "cwebdir/common.w"
+#line 1277 "cwebdir/common.w"
/*:82*/
-#line 1213 "cwebdir/common.w"
+#line 1209 "cwebdir/common.w"
if(dot_pos==NULL)
sprintf(web_file_name,"%s.w",*argv);
@@ -1520,7 +1517,7 @@ else{
strcpy(web_file_name,*argv);
*dot_pos= 0;
}
-#line 1221 "cwebdir/common.w"
+#line 1217 "cwebdir/common.w"
sprintf(tex_file_name,"%s.tex",name_pos);
sprintf(idx_file_name,"%s.idx",name_pos);
sprintf(scn_file_name,"%s.scn",name_pos);
@@ -1529,10 +1526,10 @@ found_web= true;
}
/*:77*/
-#line 1194 "cwebdir/common.w"
+#line 1188 "cwebdir/common.w"
else if(!found_change)/*78:*/
-#line 1228 "cwebdir/common.w"
+#line 1224 "cwebdir/common.w"
{
if(strcmp(*argv,"-")!=0){
@@ -1540,11 +1537,11 @@ if(s-*argv> max_file_name_length-4)
/*82:*/
#line 563 "cwebdir/comm-w2c.ch"
fatal(_("! Filename too long\n"),*argv);
-#line 1281 "cwebdir/common.w"
+#line 1277 "cwebdir/common.w"
/*:82*/
-#line 1232 "cwebdir/common.w"
+#line 1228 "cwebdir/common.w"
if(dot_pos==NULL)
sprintf(change_file_name,"%s.ch",*argv);
@@ -1554,21 +1551,21 @@ found_change= true;
}
/*:78*/
-#line 1195 "cwebdir/common.w"
+#line 1189 "cwebdir/common.w"
else if(!found_out)/*79:*/
-#line 1240 "cwebdir/common.w"
+#line 1236 "cwebdir/common.w"
{
if(s-*argv> max_file_name_length-5)
/*82:*/
#line 563 "cwebdir/comm-w2c.ch"
fatal(_("! Filename too long\n"),*argv);
-#line 1281 "cwebdir/common.w"
+#line 1277 "cwebdir/common.w"
/*:82*/
-#line 1243 "cwebdir/common.w"
+#line 1239 "cwebdir/common.w"
if(dot_pos==NULL){
sprintf(tex_file_name,"%s.tex",*argv);
@@ -1588,18 +1585,18 @@ found_out= true;
}
/*:79*/
-#line 1196 "cwebdir/common.w"
+#line 1190 "cwebdir/common.w"
else/*81:*/
#line 555 "cwebdir/comm-w2c.ch"
cb_usage(program==ctangle?"ctangle":program==cweave?"cweave":"ctwill");
-#line 1279 "cwebdir/common.w"
+#line 1275 "cwebdir/common.w"
#line 563 "cwebdir/comm-w2c.ch"
/*:81*/
-#line 1197 "cwebdir/common.w"
+#line 1191 "cwebdir/common.w"
}
}
@@ -1608,16 +1605,15 @@ if(!found_web)/*81:*/
cb_usage(program==ctangle?"ctangle":program==cweave?"cweave":"ctwill");
-#line 1279 "cwebdir/common.w"
+#line 1275 "cwebdir/common.w"
#line 563 "cwebdir/comm-w2c.ch"
/*:81*/
-#line 1200 "cwebdir/common.w"
+#line 1194 "cwebdir/common.w"
}
-#line 496 "cwebdir/comm-w2c.ch"
-/*:76*//*97:*/
+/*:75*//*97:*/
#line 812 "cwebdir/comm-w2c.ch"
static void cb_usage(const_string str)