# 2.11BSD#431 - /usr/src/ucb/pascal/pxp/var.c

##### Functions

    var               X
    varbeg            X
    varend            X

##### Variables

    varcnt            X

       1: #
       2: /*
       3:  * pxp - Pascal execution profiler
       4:  *
       5:  * Bill Joy UCB
       6:  * Version 1.2 January 1979
       7:  */
       8:
       9: #include "0.h"
      10: #include "tree.h"
      11:
      12: STATIC  int varcnt = -1;
      13: /*
      14:  * Var declaration part
      15:  */
      16: varbeg(l, vline)
      17:     int l, vline;
      18: {
      19:
      20:     line = l;
      21:     if (nodecl)
      22:         printoff();
      23:     puthedr();
      24:     putcm();
      25:     ppnl();
      26:     indent();
      27:     ppkw("var");
      28:     ppgoin(DECL);
      29:     varcnt = 0;
      30:     setline(vline);
      31: }
      32:
      33: var(vline, vidl, vtype)
      34:     int vline;
      35:     register int *vidl;
      36:     int *vtype;
      37: {
      38:
      39:     if (varcnt)
      40:         putcm();
      41:     setline(vline);
      42:     ppitem();
      43:     if (vidl != NIL)
      44:         for (;;) {
      45:             ppid(vidl[1]);
      46:             vidl = vidl[2];
      47:             if (vidl == NIL)
      48:                 break;
      49:             ppsep(", ");
      50:         }
      51:     else
      52:         ppid("{identifier list}");
      53:     ppsep(":");
      54:     gtype(vtype);
      55:     ppsep(";");
      56:     setinfo(vline);
      57:     putcml();
      58:     varcnt++;
      59: }
      60:
      61: varend()
      62: {
      63:
      64:     if (varcnt == -1)
      65:         return;
      66:     if (varcnt == 0)
      67:         ppid("{variable decls}");
      68:     ppgoout(DECL);
      69:     varcnt = -1;
      70: }

#### Defined functions

var defined in line 33; used 2 times

- in /usr/src/ucb/pascal/pxp/pas.y line 250-253(2)

varbeg defined in line 16; used 2 times

- in /usr/src/ucb/pascal/pxp/pas.y line 250, 257

varend defined in line 61; used 2 times

- in /usr/src/ucb/pascal/pxp/pas.y line 163, 181

#### Defined variables

varcnt defined in line 12; used 6 times

- in line 29, 39, 58, 64-69(3)

Last modified: 1986-06-01 Generated: 2016-12-26 | Generated by src2html V0.67 page hit count: 555 |