


     CCCCXXXXRRRREEEEFFFF((((1111))))		 XXXXEEEENNNNIIIIXXXX 3333....0000 ((((GGGGeeeeoooorrrrggggiiiiaaaa TTTTeeeecccchhhh))))	      CCCCXXXXRRRREEEEFFFF((((1111))))



     NNNNAAAAMMMMEEEE
	  cxref	- cross	reference C source files

     SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
	  ccccxxxxrrrreeeeffff	[ ----FFFFSSSSCCCCccccffffiiiissss ] [ ----wwww _w_i_d_t_h	] [files]

     DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
	  _C_x_r_e_f	reads the named	C source files and produces on the
	  standard output a cross reference of all the identifiers and
	  constants in the files.  Constants are integer constants
	  (12, 0421, 0x1A), floating point constants (123.45, 0.2e-4),
	  string constants ("this is a string\n"), and character
	  constants ('a', '\033').  Identifiers, character constants,
	  and string constants are sorted lexicographically, i.e.
	  according to the machine collating sequence (7-bit ASCII on
	  the Vax or the Pyramid).  Integer and	floating point
	  constants are	sorted numerically.  The trailing 'l' or 'L'
	  on long integer constants will not show up in	the output
	  listing.

	  If no	files are named, _c_x_r_e_f reads the standard input. For
	  multiple files, the argument "-" (a single dash) indicates
	  that the standard input should be read at that point.

	  If arguments are given, they must come before	any file
	  names.

	  _C_x_r_e_f	recognizes the following arguments:

	       ----FFFF   Fold case in comparison.  By default, case is
		    distinct in	comparison of identifiers and string
		    and	character constants.  (_c_x_r_e_f simply passes the
		    "-F" option	on to _s_o_r_t(1) as "-f".)

	       ----SSSS   Cross reference all	files separately.  The default
		    action is to cross reference all named files
		    together.

	       ----cccc   Leave character constants out of the cross
		    reference listing.

	       ----ffff   Leave floating point constants out of the cross
		    reference listing.

	       ----iiii   Leave integer constants out	of the cross reference
		    listing.

	       ----ssss   Leave string constants out of the cross reference
		    listing.

	       ----CCCC   Leave _a_l_l constants, character, string, integer,
		    and	floating point,	out of the cross reference



     Page 1					    (printed 10/24/94)






     CCCCXXXXRRRREEEEFFFF((((1111))))		 XXXXEEEENNNNIIIIXXXX 3333....0000 ((((GGGGeeeeoooorrrrggggiiiiaaaa TTTTeeeecccchhhh))))	      CCCCXXXXRRRREEEEFFFF((((1111))))



		    listing.  By default, all types of constants are
		    included in	the cross reference.

	       ----wwww _w_i_d_t_h
		    Make the output be _w_i_d_t_h columns wide.  The	output
		    width will never be	less than 51 or	more than 132
		    columns.  _C_x_r_e_f silently adjusts incorrect
		    settings to	the nearest allowable setting.	If no
		    width is specified,	the output will	default	to 80
		    columns wide.

	  _C_x_r_e_f	does _n_o_t include #include files, or expand macro
	  definitions.	Files named in #include	lines can be listed on
	  the command line if they should also be cross	referenced.

	  If a quoted string has an escaped newline in it (see ``The C
	  Programming Language'', page 181, or Section 2.5 of the C
	  Reference Manual), it	will show up inside the	string in the
	  output listing as \N.	 This is to make it visible to the
	  programmer, and to keep the various filters which _C_x_r_e_f uses
	  to actually do the work from getting terribly	confused.

	  _C_x_r_e_f	is best	run in the background, with its	output
	  redirected into a file or the	line printer spooler _l_p_r(1),
	  since	it reads all the named files, using _s_o_r_t(1) as an
	  intermediate pass.  The sorting can take time	which the user
	  can probably put to more productive use.

     DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
	  Self explanatory.

     BBBBUUUUGGGGSSSS
	  Systems running UNIX 4.0 and later already have a program
	  named	_c_x_r_e_f.	Therefore, on those systems, this program
	  should be renamed.

	  _C_x_r_e_f	does not do any	formatting on its output (other	than
	  to insure that it writes the proper number of	columns), so
	  it should probably be	run piping its output into _p_r(1).

	  Floating point constants are converted to a common format
	  for sorting, therefore they may appear in the	output in a
	  format different from	(but numerically equivalent to)	their
	  form in the original source code.

     SSSSEEEEEEEE AAAALLLLSSSSOOOO
	  _l_e_x(1), _l_p_r(1), _p_r(1), _s_o_r_t(1)

     FFFFIIIILLLLEEEESSSS
	  /tmp/cxr.$$.*
	       temporary files for integer and floating	point
	       contstants.  _C_x_r_e_f removes these	files when it is



     Page 2					    (printed 10/24/94)






     CCCCXXXXRRRREEEEFFFF((((1111))))		 XXXXEEEENNNNIIIIXXXX 3333....0000 ((((GGGGeeeeoooorrrrggggiiiiaaaa TTTTeeeecccchhhh))))	      CCCCXXXXRRRREEEEFFFF((((1111))))



	       through.

     AAAAUUUUTTTTHHHHOOOORRRR
	  Arnold Robbins
	  School of Information	and Computer Science
	  Georgia Institute of Technology
	  Atlanta, Geogia  30332

	  UUCP:	    gatech!arnold
	  CSNET:    arnold@gatech
	  ARPANET:  arnold%gatech.csnet@csnet-relay.arpa

	  Copyright (c)	1984 by	Arnold Robbins.	 All rights reserved.
	  This program may not be sold,	but may	be distributed
	  provided this	notice is included.








































     Page 3					    (printed 10/24/94)



