1: #
   2: /*
   3:  * sed -- stream  editor
   4:  *
   5:  *
   6:  */
   7: 
   8: #define CBRA    1
   9: #define CCHR    2
  10: #define CDOT    4
  11: #define CCL 6
  12: #define CNL 8
  13: #define CDOL    10
  14: #define CEOF    11
  15: #define CKET    12
  16: #define CNULL   13
  17: #define CLNUM   14
  18: #define CEND    16
  19: #define CDONT   17
  20: #define CBACK   18
  21: 
  22: #define STAR    01
  23: 
  24: #define NLINES  256
  25: #define DEPTH   20
  26: #define PTRSIZE 100
  27: #define RESIZE  5000
  28: #define ABUFSIZE    20
  29: #define LBSIZE  4000
  30: #define ESIZE   256
  31: #define LABSIZE 50
  32: #define NBRA    9
  33: 
  34: FILE    *fin;
  35: union reptr *abuf[ABUFSIZE];
  36: union reptr **aptr;
  37: char    *lastre;
  38: char    ibuf[512];
  39: char    *cbp;
  40: char    *ebp;
  41: char    genbuf[LBSIZE];
  42: char    *loc1;
  43: char    *loc2;
  44: char    *locs;
  45: char    seof;
  46: char    *reend;
  47: char    *lbend;
  48: char    *hend;
  49: char    *lcomend;
  50: union reptr *ptrend;
  51: int eflag;
  52: int dolflag;
  53: int sflag;
  54: int jflag;
  55: int numbra;
  56: int delflag;
  57: long    lnum;
  58: char    linebuf[LBSIZE+1];
  59: char    holdsp[LBSIZE+1];
  60: char    *spend;
  61: char    *hspend;
  62: int nflag;
  63: int gflag;
  64: char    *braelist[NBRA];
  65: char    *braslist[NBRA];
  66: long    tlno[NLINES];
  67: int nlno;
  68: char    fname[12][40];
  69: FILE    *fcode[12];
  70: int nfiles;
  71: 
  72: #define ACOM    01
  73: #define BCOM    020
  74: #define CCOM    02
  75: #define CDCOM   025
  76: #define CNCOM   022
  77: #define COCOM   017
  78: #define CPCOM   023
  79: #define DCOM    03
  80: #define ECOM    015
  81: #define EQCOM   013
  82: #define FCOM    016
  83: #define GCOM    027
  84: #define CGCOM   030
  85: #define HCOM    031
  86: #define CHCOM   032
  87: #define ICOM    04
  88: #define LCOM    05
  89: #define NCOM    012
  90: #define PCOM    010
  91: #define QCOM    011
  92: #define RCOM    06
  93: #define SCOM    07
  94: #define TCOM    021
  95: #define WCOM    014
  96: #define CWCOM   024
  97: #define YCOM    026
  98: #define XCOM    033
  99: 
 100: char    *cp;
 101: char    *reend;
 102: char    *lbend;
 103: 
 104: union   reptr {
 105:     struct reptr1 {
 106:         char    *ad1;
 107:         char    *ad2;
 108:         char    *re1;
 109:         char    *rhs;
 110:         FILE    *fcode;
 111:         char    command;
 112:         char    gfl;
 113:         char    pfl;
 114:         char    inar;
 115:         char    negfl;
 116:     };
 117:     struct reptr2 {
 118:         char    *ad1;
 119:         char    *ad2;
 120:         union reptr *lb1;
 121:         char    *rhs;
 122:         FILE    *fcode;
 123:         char    command;
 124:         char    gfl;
 125:         char    pfl;
 126:         char    inar;
 127:         char    negfl;
 128:     };
 129: } ptrspace[PTRSIZE], *rep;
 130: 
 131: 
 132: char    respace[RESIZE];
 133: 
 134: struct label {
 135:     char    asc[9];
 136:     union reptr *chain;
 137:     union reptr *address;
 138: } ltab[LABSIZE];
 139: 
 140: struct label    *lab;
 141: struct label    *labend;
 142: 
 143: int f;
 144: int depth;
 145: 
 146: int eargc;
 147: char    **eargv;
 148: 
 149: extern  char    bittab[];
 150: 
 151: union reptr **cmpend[DEPTH];
 152: int depth;
 153: union reptr *pending;
 154: char    *badp;
 155: char    bad;
 156: char    *compile();
 157: char    *ycomp();
 158: char    *address();
 159: char    *text();
 160: char    *compsub();
 161: struct label    *search();
 162: char    *gline();
 163: char    *place();
 164: char    compfl;

Defined variables

abuf defined in line 35; used 9 times
aptr defined in line 36; used 18 times
bad defined in line 155; used 1 times
badp defined in line 154; used 23 times
braelist defined in line 64; used 4 times
braslist defined in line 65; used 5 times
cbp defined in line 39; used 3 times
cmpend defined in line 151; used 2 times
compfl defined in line 164; used 2 times
cp defined in line 100; used 74 times
delflag defined in line 56; used 8 times
depth defined in line 152; used 5 times
dolflag defined in line 52; used 3 times
eargc defined in line 146; used 10 times
eargv defined in line 147; used 10 times
ebp defined in line 40; used 5 times
eflag defined in line 51; used 7 times
f defined in line 143; used 6 times
fname defined in line 68; used 10 times
genbuf defined in line 41; used 19 times
gflag defined in line 63; used 2 times
hend defined in line 48; used 2 times
holdsp defined in line 59; used 7 times
hspend defined in line 61; used 6 times
ibuf defined in line 38; used 8 times
jflag defined in line 54; used 5 times
lab defined in line 140; used 14 times
labend defined in line 141; used 3 times
lastre defined in line 37; used 2 times
lbend defined in line 102; used 3 times
lcomend defined in line 49; used 4 times
linebuf defined in line 58; used 63 times
lnum defined in line 57; used 8 times
loc1 defined in line 42; used 5 times
loc2 defined in line 43; used 6 times
locs defined in line 44; used 3 times
ltab defined in line 138; used 1 times
nfiles defined in line 70; used 15 times
nflag defined in line 62; used 5 times
nlno defined in line 67; used 3 times
numbra defined in line 55; used 5 times
pending defined in line 153; used 6 times
ptrend defined in line 50; used 3 times
ptrspace defined in line 129; used 5 times
reend defined in line 101; used 5 times
rep defined in line 129; used 92 times
respace defined in line 132; used 2 times
seof defined in line 45; used 11 times
sflag defined in line 53; used 3 times
spend defined in line 60; used 18 times
tlno defined in line 66; used 4 times

Defined struct's

label defined in line 134; used 18 times
reptr1 defined in line 105; never used
reptr2 defined in line 117; never used

Defined union's

reptr defined in line 104; used 23 times

Defined macros

ABUFSIZE defined in line 28; used 3 times
ACOM defined in line 72; used 2 times
BCOM defined in line 73; used 2 times
CBACK defined in line 20; used 3 times
CBRA defined in line 8; used 1 times
CCHR defined in line 9; used 5 times
CCL defined in line 11; used 2 times
CCOM defined in line 74; used 1 times
CDCOM defined in line 75; used 1 times
CDOL defined in line 13; used 1 times
CDONT defined in line 19; never used
CDOT defined in line 10; used 2 times
CEND defined in line 18; used 3 times
CEOF defined in line 14; used 3 times
CGCOM defined in line 84; used 1 times
CHCOM defined in line 86; used 1 times
CKET defined in line 15; used 2 times
CLNUM defined in line 17; used 3 times
CNCOM defined in line 76; used 1 times
CNL defined in line 12; never used
CNULL defined in line 16; never used
COCOM defined in line 77; never used
CPCOM defined in line 78; used 1 times
CWCOM defined in line 96; never used
DCOM defined in line 79; used 1 times
DEPTH defined in line 25; used 1 times
ECOM defined in line 80; never used
EQCOM defined in line 81; used 1 times
ESIZE defined in line 30; used 2 times
FCOM defined in line 82; never used
GCOM defined in line 83; used 1 times
HCOM defined in line 85; used 1 times
ICOM defined in line 87; used 1 times
LABSIZE defined in line 31; used 2 times
LBSIZE defined in line 29; used 8 times
LCOM defined in line 88; used 1 times
NBRA defined in line 32; used 5 times
NCOM defined in line 89; used 1 times
NLINES defined in line 24; used 2 times
PCOM defined in line 90; used 1 times
PTRSIZE defined in line 26; used 2 times
QCOM defined in line 91; used 1 times
RCOM defined in line 92; used 1 times
RESIZE defined in line 27; used 2 times
SCOM defined in line 93; used 1 times
STAR defined in line 22; used 1 times
TCOM defined in line 94; used 1 times
WCOM defined in line 95; used 1 times
XCOM defined in line 98; used 1 times
YCOM defined in line 97; used 1 times

Usage of this include

Last modified: 1981-07-10
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 1262
Valid CSS Valid XHTML 1.0 Strict