From 52575967e95997a95304ffde4439c1cf230ef092 Mon Sep 17 00:00:00 2001 From: Peter Breitenlohner Date: Mon, 18 Jan 2010 16:11:52 +0000 Subject: cleanup extern declarations git-svn-id: svn://tug.org/texlive/trunk@16772 c570f23f-e606-0410-a88d-b1316a301751 --- Build/source/texk/web2c/ctangleboot.cin | 68 ++++++++++++++-------------- Build/source/texk/web2c/cwebboot.cin | 4 +- Build/source/texk/web2c/cwebboot.hin | 1 + Build/source/texk/web2c/cwebdir/ChangeLog | 5 ++ Build/source/texk/web2c/cwebdir/comm-w2c.ch | 1 + Build/source/texk/web2c/cwebdir/ctang-w2c.ch | 2 - Build/source/texk/web2c/cwebdir/cweav-w2c.ch | 2 - Build/source/texk/web2c/pdftexdir/ChangeLog | 10 ++++ Build/source/texk/web2c/pdftexdir/epdf.c | 1 - Build/source/texk/web2c/pdftexdir/pkin.c | 2 - Build/source/texk/web2c/pdftexdir/ptexlib.h | 3 ++ Build/source/texk/web2c/pdftexdir/writet1.c | 1 - Build/source/texk/web2c/pdftexdir/writettf.c | 3 -- Build/source/texk/web2c/web2c/ChangeLog | 4 ++ Build/source/texk/web2c/web2c/main.c | 2 - 15 files changed, 59 insertions(+), 50 deletions(-) diff --git a/Build/source/texk/web2c/ctangleboot.cin b/Build/source/texk/web2c/ctangleboot.cin index c66069ae672..727ff5a22ea 100644 --- a/Build/source/texk/web2c/ctangleboot.cin +++ b/Build/source/texk/web2c/ctangleboot.cin @@ -6,8 +6,6 @@ #line 93 "cwebdir/ctang-w2c.ch" #include - -extern char*versionstring; #include #line 37 "cwebdir/common.h" @@ -192,21 +190,21 @@ extern char*byte_ptr; extern name_pointer hash[]; extern hash_pointer hash_end; extern hash_pointer h; -#line 106 "cwebdir/ctang-w2c.ch" +#line 104 "cwebdir/ctang-w2c.ch" #include "cwebboot.h" #line 112 "cwebdir/common.h" /*:8*//*9:*/ #line 122 "cwebdir/common.h" -#line 118 "cwebdir/ctang-w2c.ch" +#line 116 "cwebdir/ctang-w2c.ch" extern int history; #line 128 "cwebdir/common.h" /*:9*//*10:*/ #line 137 "cwebdir/common.h" -#line 132 "cwebdir/ctang-w2c.ch" +#line 130 "cwebdir/ctang-w2c.ch" extern int include_depth; #line 139 "cwebdir/common.h" extern FILE*file[]; @@ -218,7 +216,7 @@ extern char scn_file_name[]; extern char file_name[][max_file_name_length]; extern char change_file_name[]; -#line 139 "cwebdir/ctang-w2c.ch" +#line 137 "cwebdir/ctang-w2c.ch" extern int line[]; extern int change_line; #line 150 "cwebdir/common.h" @@ -370,35 +368,35 @@ extern sixteen_bits section_count; /*40:*/ #line 533 "cwebdir/ctangle.w" -#line 241 "cwebdir/ctang-w2c.ch" +#line 239 "cwebdir/ctang-w2c.ch" static void phase_two(void); #line 535 "cwebdir/ctangle.w" /*:40*//*45:*/ #line 602 "cwebdir/ctangle.w" -#line 259 "cwebdir/ctang-w2c.ch" +#line 257 "cwebdir/ctang-w2c.ch" static void output_defs(void); #line 604 "cwebdir/ctangle.w" /*:45*//*47:*/ #line 648 "cwebdir/ctangle.w" -#line 277 "cwebdir/ctang-w2c.ch" +#line 275 "cwebdir/ctang-w2c.ch" static void out_char(eight_bits); #line 650 "cwebdir/ctangle.w" /*:47*//*89:*/ #line 1457 "cwebdir/ctangle.w" -#line 372 "cwebdir/ctang-w2c.ch" +#line 370 "cwebdir/ctang-w2c.ch" static void phase_one(void); #line 1459 "cwebdir/ctangle.w" /*:89*//*91:*/ #line 1475 "cwebdir/ctangle.w" -#line 390 "cwebdir/ctang-w2c.ch" +#line 388 "cwebdir/ctang-w2c.ch" static void skip_limbo(void); #line 1477 "cwebdir/ctangle.w" @@ -487,7 +485,7 @@ return wrap_up(); /*:2*//*20:*/ #line 183 "cwebdir/ctangle.w" -#line 165 "cwebdir/ctang-w2c.ch" +#line 163 "cwebdir/ctang-w2c.ch" int names_match(name_pointer p,const char*first,int l,char t) #line 188 "cwebdir/ctangle.w" { @@ -499,21 +497,21 @@ return!strncmp(first,p->byte_start,l); #line 198 "cwebdir/ctangle.w" void -#line 174 "cwebdir/ctang-w2c.ch" +#line 172 "cwebdir/ctang-w2c.ch" init_node(name_pointer node) #line 202 "cwebdir/ctangle.w" { node->equiv= (char*)text_info; } void -#line 180 "cwebdir/ctang-w2c.ch" +#line 178 "cwebdir/ctang-w2c.ch" init_p(name_pointer p,char t){} #line 207 "cwebdir/ctangle.w" /*:21*//*25:*/ #line 260 "cwebdir/ctangle.w" -#line 190 "cwebdir/ctang-w2c.ch" +#line 188 "cwebdir/ctang-w2c.ch" static void store_two_bytes(sixteen_bits x) #line 264 "cwebdir/ctangle.w" @@ -526,7 +524,7 @@ if(tok_ptr+2> tok_mem_end)overflow("token"); /*:25*//*29:*/ #line 336 "cwebdir/ctangle.w" -#line 201 "cwebdir/ctang-w2c.ch" +#line 199 "cwebdir/ctang-w2c.ch" static void push_level(name_pointer p) #line 340 "cwebdir/ctangle.w" @@ -544,7 +542,7 @@ cur_section= 0; /*:29*//*30:*/ #line 355 "cwebdir/ctangle.w" -#line 212 "cwebdir/ctang-w2c.ch" +#line 210 "cwebdir/ctang-w2c.ch" static void pop_level(int flag) #line 359 "cwebdir/ctangle.w" @@ -561,7 +559,7 @@ if(stack_ptr> stack)cur_state= *stack_ptr; /*:30*//*32:*/ #line 391 "cwebdir/ctangle.w" -#line 222 "cwebdir/ctang-w2c.ch" +#line 220 "cwebdir/ctang-w2c.ch" static void get_output(void) #line 394 "cwebdir/ctangle.w" @@ -610,7 +608,7 @@ out_char(section_number); /*:32*//*36:*/ #line 481 "cwebdir/ctangle.w" -#line 232 "cwebdir/ctang-w2c.ch" +#line 230 "cwebdir/ctang-w2c.ch" static void flush_buffer(void) #line 484 "cwebdir/ctangle.w" @@ -627,7 +625,7 @@ cur_line++; /*:36*//*41:*/ #line 536 "cwebdir/ctangle.w" -#line 250 "cwebdir/ctang-w2c.ch" +#line 248 "cwebdir/ctang-w2c.ch" static void phase_two(void){ #line 539 "cwebdir/ctangle.w" @@ -702,7 +700,7 @@ if(show_happiness)printf("\nDone."); /*:41*//*46:*/ #line 605 "cwebdir/ctangle.w" -#line 268 "cwebdir/ctang-w2c.ch" +#line 266 "cwebdir/ctang-w2c.ch" static void output_defs(void) #line 608 "cwebdir/ctangle.w" @@ -745,7 +743,7 @@ pop_level(0); #line 651 "cwebdir/ctangle.w" static void -#line 286 "cwebdir/ctang-w2c.ch" +#line 284 "cwebdir/ctang-w2c.ch" out_char(eight_bits cur_char) #line 655 "cwebdir/ctangle.w" { @@ -846,7 +844,7 @@ default:C_putc(cur_char);out_state= normal;break; /*:48*//*57:*/ #line 813 "cwebdir/ctangle.w" -#line 295 "cwebdir/ctang-w2c.ch" +#line 293 "cwebdir/ctang-w2c.ch" static eight_bits skip_ahead(void) #line 816 "cwebdir/ctangle.w" @@ -866,7 +864,7 @@ if(c!=ignore||*(loc-1)=='>')return(c); /*:57*//*59:*/ #line 848 "cwebdir/ctangle.w" -#line 305 "cwebdir/ctang-w2c.ch" +#line 303 "cwebdir/ctang-w2c.ch" static int skip_comment(boolean is_long_comment) #line 851 "cwebdir/ctangle.w" @@ -902,7 +900,7 @@ else loc++; /*:59*//*62:*/ #line 900 "cwebdir/ctangle.w" -#line 322 "cwebdir/ctang-w2c.ch" +#line 320 "cwebdir/ctang-w2c.ch" static eight_bits get_next(void) #line 903 "cwebdir/ctangle.w" @@ -924,7 +922,7 @@ else id_first= cur_file_name; id_loc= id_first+strlen(id_first); if(changing)store_two_bytes((sixteen_bits)change_line); else store_two_bytes((sixteen_bits)cur_line); -#line 353 "cwebdir/ctang-w2c.ch" +#line 351 "cwebdir/ctang-w2c.ch" {int a_l= id_lookup(id_first,id_loc,0)-name_dir;app_repl((a_l/0400)+0200); app_repl(a_l%0400);} #line 1234 "cwebdir/ctangle.w" @@ -1188,7 +1186,7 @@ mistake:/*63:*/ switch(c){ case'+':if(*loc=='+')compress(plus_plus);break; case'-':if(*loc=='-'){compress(minus_minus);} -#line 332 "cwebdir/ctang-w2c.ch" +#line 330 "cwebdir/ctang-w2c.ch" else if(*loc=='>'){if(*(loc+1)=='*'){loc++;compress(minus_gt_ast);} else compress(minus_gt);}break; #line 956 "cwebdir/ctangle.w" @@ -1218,7 +1216,7 @@ return(c); /*:62*//*75:*/ #line 1199 "cwebdir/ctangle.w" -#line 343 "cwebdir/ctang-w2c.ch" +#line 341 "cwebdir/ctang-w2c.ch" static void scan_repl(eight_bits t) #line 1203 "cwebdir/ctangle.w" @@ -1233,7 +1231,7 @@ else id_first= cur_file_name; id_loc= id_first+strlen(id_first); if(changing)store_two_bytes((sixteen_bits)change_line); else store_two_bytes((sixteen_bits)cur_line); -#line 353 "cwebdir/ctang-w2c.ch" +#line 351 "cwebdir/ctang-w2c.ch" {int a_l= id_lookup(id_first,id_loc,0)-name_dir;app_repl((a_l/0400)+0200); app_repl(a_l%0400);} #line 1234 "cwebdir/ctangle.w" @@ -1278,7 +1276,7 @@ else id_first= cur_file_name; id_loc= id_first+strlen(id_first); if(changing)store_two_bytes((sixteen_bits)change_line); else store_two_bytes((sixteen_bits)cur_line); -#line 353 "cwebdir/ctang-w2c.ch" +#line 351 "cwebdir/ctang-w2c.ch" {int a_l= id_lookup(id_first,id_loc,0)-name_dir;app_repl((a_l/0400)+0200); app_repl(a_l%0400);} #line 1234 "cwebdir/ctangle.w" @@ -1303,7 +1301,7 @@ else id_first= cur_file_name; id_loc= id_first+strlen(id_first); if(changing)store_two_bytes((sixteen_bits)change_line); else store_two_bytes((sixteen_bits)cur_line); -#line 353 "cwebdir/ctang-w2c.ch" +#line 351 "cwebdir/ctang-w2c.ch" {int a_l= id_lookup(id_first,id_loc,0)-name_dir;app_repl((a_l/0400)+0200); app_repl(a_l%0400);} #line 1234 "cwebdir/ctangle.w" @@ -1409,7 +1407,7 @@ cur_text= text_ptr;(++text_ptr)->tok_start= tok_ptr; /*:75*//*82:*/ #line 1357 "cwebdir/ctangle.w" -#line 363 "cwebdir/ctang-w2c.ch" +#line 361 "cwebdir/ctang-w2c.ch" static void scan_section(void) #line 1360 "cwebdir/ctangle.w" @@ -1522,7 +1520,7 @@ cur_text->text_link= section_flag; /*:82*//*90:*/ #line 1460 "cwebdir/ctangle.w" -#line 381 "cwebdir/ctang-w2c.ch" +#line 379 "cwebdir/ctang-w2c.ch" static void phase_one(void){ #line 1463 "cwebdir/ctangle.w" @@ -1538,7 +1536,7 @@ phase= 2; /*:90*//*92:*/ #line 1478 "cwebdir/ctangle.w" -#line 399 "cwebdir/ctang-w2c.ch" +#line 397 "cwebdir/ctang-w2c.ch" static void skip_limbo(void) #line 1481 "cwebdir/ctangle.w" @@ -1599,7 +1597,7 @@ default:err_print("! Double @ should be used in limbo"); #line 1533 "cwebdir/ctangle.w" void -#line 408 "cwebdir/ctang-w2c.ch" +#line 406 "cwebdir/ctang-w2c.ch" print_stats(void){ #line 1536 "cwebdir/ctangle.w" printf("\nMemory usage statistics:\n"); diff --git a/Build/source/texk/web2c/cwebboot.cin b/Build/source/texk/web2c/cwebboot.cin index 81dc2c18fde..1ecc14bcd56 100644 --- a/Build/source/texk/web2c/cwebboot.cin +++ b/Build/source/texk/web2c/cwebboot.cin @@ -1122,7 +1122,7 @@ if((**(++argv)=='-'||**argv=='+')&&*(*argv+1))/*76:*/ { if(strcmp("-help",*argv)==0||strcmp("--help",*argv)==0) /*86:*/ -#line 711 "cwebdir/comm-w2c.ch" +#line 712 "cwebdir/comm-w2c.ch" usagehelp(program==ctangle?CTANGLEHELP:CWEAVEHELP,NULL); @@ -1132,7 +1132,7 @@ usagehelp(program==ctangle?CTANGLEHELP:CWEAVEHELP,NULL); ; if(strcmp("-version",*argv)==0||strcmp("--version",*argv)==0) /*87:*/ -#line 720 "cwebdir/comm-w2c.ch" +#line 721 "cwebdir/comm-w2c.ch" printversionandexit((program==ctangle?ctangle_banner:cweave_banner), "Silvio Levy and Donald E. Knuth",NULL,NULL); diff --git a/Build/source/texk/web2c/cwebboot.hin b/Build/source/texk/web2c/cwebboot.hin index f8bcfe89d80..8360442207a 100644 --- a/Build/source/texk/web2c/cwebboot.hin +++ b/Build/source/texk/web2c/cwebboot.hin @@ -60,5 +60,6 @@ extern name_pointer section_lookup(char*first,char*last,int ispref); /*:83*/ #line 705 "cwebdir/comm-w2c.ch" +extern const char*versionstring; /*:84*/ diff --git a/Build/source/texk/web2c/cwebdir/ChangeLog b/Build/source/texk/web2c/cwebdir/ChangeLog index 09eeb4cfc95..74ba38427b7 100644 --- a/Build/source/texk/web2c/cwebdir/ChangeLog +++ b/Build/source/texk/web2c/cwebdir/ChangeLog @@ -1,3 +1,8 @@ +2010-01-18 Peter Breitenlohner + + * {comm,ctang,cweav}-w2c.ch: Move extern declaration of + versionstring from {ctangle,cweave}.c to cweb.h. + 2009-08-29 Peter Breitenlohner * {comm,ctang,cweav}-w2c.ch: Create a header file cweb.h with diff --git a/Build/source/texk/web2c/cwebdir/comm-w2c.ch b/Build/source/texk/web2c/cwebdir/comm-w2c.ch index 22b70066f42..6cbee2fc400 100644 --- a/Build/source/texk/web2c/cwebdir/comm-w2c.ch +++ b/Build/source/texk/web2c/cwebdir/comm-w2c.ch @@ -703,6 +703,7 @@ in \.{common.w} and used in \.{ctangle.w} and \.{cweave.w} or vice versa. @= * declared in common.w and used in ctangle.w and cweave.w, or@> @= * used in common.w and declared in ctangle.w and cweave.w. */@> @@; +extern const char *versionstring; @** System dependent changes. diff --git a/Build/source/texk/web2c/cwebdir/ctang-w2c.ch b/Build/source/texk/web2c/cwebdir/ctang-w2c.ch index 38d60422f6d..82aec2d9f49 100644 --- a/Build/source/texk/web2c/cwebdir/ctang-w2c.ch +++ b/Build/source/texk/web2c/cwebdir/ctang-w2c.ch @@ -91,8 +91,6 @@ Section 6. #include @y #include -/* #include "cpascal.h" ??? */ -extern char *versionstring; #include @z diff --git a/Build/source/texk/web2c/cwebdir/cweav-w2c.ch b/Build/source/texk/web2c/cwebdir/cweav-w2c.ch index 11058fb5172..c41711237e0 100644 --- a/Build/source/texk/web2c/cwebdir/cweav-w2c.ch +++ b/Build/source/texk/web2c/cwebdir/cweav-w2c.ch @@ -103,8 +103,6 @@ Section 6. #include @y #include -/* #include "cpascal.h" ??? */ -extern char *versionstring; #include @z diff --git a/Build/source/texk/web2c/pdftexdir/ChangeLog b/Build/source/texk/web2c/pdftexdir/ChangeLog index 0d2eef9acae..78d059f5b04 100644 --- a/Build/source/texk/web2c/pdftexdir/ChangeLog +++ b/Build/source/texk/web2c/pdftexdir/ChangeLog @@ -1,3 +1,13 @@ +2010-01-18 Peter Breitenlohner + + * epdf.c: Remove extern delaration of register_fd_entry(). + * pkin.c: Remove extern delaration of t3_file. + * writet1.c: Remove extern delaration of fb_array. + * writettf.c: Remove extern delarations of fb_array and + charsetstr. + * ptexlib.h: Add extern delarations of fb_array, t3_file, and + register_fd_entry(). + 2009-12-12 Peter Breitenlohner * am/pdftex.am: Replace the obsolete $(mkdir_p) by $(MKDIR_P). diff --git a/Build/source/texk/web2c/pdftexdir/epdf.c b/Build/source/texk/web2c/pdftexdir/epdf.c index 9167e7a7b07..a4404c45e60 100644 --- a/Build/source/texk/web2c/pdftexdir/epdf.c +++ b/Build/source/texk/web2c/pdftexdir/epdf.c @@ -22,7 +22,6 @@ Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. #include extern void epdf_check_mem(void); -extern void register_fd_entry(fd_entry *); int is_subsetable(fm_entry * fm) diff --git a/Build/source/texk/web2c/pdftexdir/pkin.c b/Build/source/texk/web2c/pdftexdir/pkin.c index 131ac2e1943..52530cde437 100644 --- a/Build/source/texk/web2c/pdftexdir/pkin.c +++ b/Build/source/texk/web2c/pdftexdir/pkin.c @@ -52,8 +52,6 @@ Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. /* static FILE *pkfile ; */ - -extern FILE *t3_file; #define pkfile t3_file static shalfword pkbyte(void) diff --git a/Build/source/texk/web2c/pdftexdir/ptexlib.h b/Build/source/texk/web2c/pdftexdir/ptexlib.h index a925988392a..227645d3f92 100644 --- a/Build/source/texk/web2c/pdftexdir/ptexlib.h +++ b/Build/source/texk/web2c/pdftexdir/ptexlib.h @@ -162,6 +162,8 @@ extern integer t1_length1, t1_length2, t1_length3; extern integer ttf_length; extern strnumber last_tex_string; extern size_t last_ptr_index; +extern char *fb_array; +extern FILE *t3_file; /* pdftexlib function prototypes */ @@ -289,6 +291,7 @@ extern void dopdffont(integer, internalfontnumber); extern fd_entry *lookup_fd_entry(char *, integer, integer); extern fd_entry *new_fd_entry(void); extern void writefontstuff(); +extern void register_fd_entry(fd_entry *); /* writeimg.c */ extern boolean checkimageb(integer); diff --git a/Build/source/texk/web2c/pdftexdir/writet1.c b/Build/source/texk/web2c/pdftexdir/writet1.c index 72a4e85e90b..2ea62fe1727 100644 --- a/Build/source/texk/web2c/pdftexdir/writet1.c +++ b/Build/source/texk/web2c/pdftexdir/writet1.c @@ -113,7 +113,6 @@ static const char *standard_glyph_names[256] = { integer t1_length1, t1_length2, t1_length3; static integer t1_save_offset; static integer t1_fontname_offset; -extern char *fb_array; static fd_entry *fd_cur; static char charstringname[] = "/CharStrings"; diff --git a/Build/source/texk/web2c/pdftexdir/writettf.c b/Build/source/texk/web2c/pdftexdir/writettf.c index d6711b486c2..8dcaf80e06d 100644 --- a/Build/source/texk/web2c/pdftexdir/writettf.c +++ b/Build/source/texk/web2c/pdftexdir/writettf.c @@ -106,9 +106,6 @@ integer ttf_length; #include "macnames.c" -extern char *fb_array; -extern char charsetstr[]; - static const char *newtabnames[] = { "OS/2", "PCLT", diff --git a/Build/source/texk/web2c/web2c/ChangeLog b/Build/source/texk/web2c/web2c/ChangeLog index 490c000ba55..c279bf007d3 100644 --- a/Build/source/texk/web2c/web2c/ChangeLog +++ b/Build/source/texk/web2c/web2c/ChangeLog @@ -1,3 +1,7 @@ +2010-01-18 Peter Breitenlohner + + * main.c: Remove unused extern declaration of yylen. + 2009-12-14 Karl Berry * convert.bat: remove, obsolete. diff --git a/Build/source/texk/web2c/web2c/main.c b/Build/source/texk/web2c/web2c/main.c index 9a872b2ab61..bec91001847 100644 --- a/Build/source/texk/web2c/web2c/main.c +++ b/Build/source/texk/web2c/web2c/main.c @@ -62,8 +62,6 @@ struct sym_entry sym_table[sym_table_size]; int next_sym_free = -1, next_string_free = 0; int mark_sym_free, mark_string_free; -extern int yyleng; - void find_next_temp (void) { -- cgit v1.2.3