Annotation of coherent/d/bin/nroff/str.h, revision 1.1.1.1

1.1       root        1: /*
                      2:  * str.h
                      3:  * Nroff/Troff.
                      4:  * Input stack header.
                      5:  */
                      6: 
                      7: #define SREQS  0                       /* Request                      */
                      8: #define SSINP  1                       /* Insertion from standard input */
                      9: #define SFILE  2                       /* File I/O                     */
                     10: #define SCORE  3                       /* Core I/O                     */
                     11: #define SCTEX  4                       /* Chained text                 */
                     12: #define SCDIV  5                       /* Chained diversion            */
                     13: 
                     14: #define ARGSIZE        10                      /* Maximum number of arguments  */
                     15: 
                     16: /*
                     17:  * Used for stacking input sources.
                     18:  */
                     19: typedef union STR {
                     20:        struct  x1 {                    /* Used for insertions from stdin */
                     21:                union STR *s_next;      /* Pointer to next in stack     */
                     22:                int     s_type;         /* Type of input                */
                     23:                int     s_eoff;         /* End of file flag             */
                     24:                int     s_clnc;         /* Current line number          */
                     25:                int     s_nlnc;         /* Last line number             */
                     26:                int     s_argc;         /* Number of arguments          */
                     27:                char    *s_argp[ARGSIZE];       /* Pointer to arguments */
                     28:                char    *s_abuf;        /* Arg buffer space             */
                     29:        } x1;
                     30:        struct  x2 {                    /* File I/O                     */
                     31:                union STR *s_next;      /* Pointer to next in stack     */
                     32:                int     s_type;         /* Type of input                */
                     33:                int     s_eoff;         /* End of file flag             */
                     34:                int     s_clnc;         /* Current line number          */
                     35:                int     s_nlnc;         /* Last line number             */
                     36:                int     s_argc;         /* Number of arguments          */
                     37:                char    *s_argp[ARGSIZE];       /* Pointer to arguments */
                     38:                char    *s_abuf;        /* Arg buffer space             */
                     39:                char    *s_fname;       /* File name                    */
                     40:                FILE    *s_fp;          /* File pointer                 */
                     41:        } x2;
                     42:        struct  x3 {                    /* Core I/O                     */
                     43:                union STR *s_next;      /* Pointer to next in stack     */
                     44:                int     s_type;         /* Type of input                */
                     45:                int     s_eoff;         /* End of file flag             */
                     46:                int     s_clnc;         /* Current line number          */
                     47:                int     s_nlnc;         /* Last line number             */
                     48:                int     s_argc;         /* Number of arguments          */
                     49:                char    *s_argp[ARGSIZE];       /* Pointer to arguments */
                     50:                char    *s_abuf;        /* Arg buffer space             */
                     51:                char    *s_cp;          /* Pointer in core              */
                     52:                char    *s_srel;        /* Released when unstacked      */
                     53:        } x3;
                     54:        struct  x4 {                    /* Chained I/O                  */
                     55:                union STR *s_next;      /* Pointer to next in stack     */
                     56:                int     s_type;         /* Type of input                */
                     57:                int     s_eoff;         /* End of file flag             */
                     58:                int     s_clnc;         /* Current line number          */
                     59:                int     s_nlnc;         /* Last line number             */
                     60:                int     s_argc;         /* Number of arguments          */
                     61:                char    *s_argp[ARGSIZE];       /* Pointer to arguments */
                     62:                char    *s_abuf;        /* Arg buffer space             */
                     63:                char    *s_bufp;        /* Pointer to buffer            */
                     64:                char    *s_bufend;      /* End of buffer in core        */
                     65:                union MAC *s_macp;      /* Next in chain list           */
                     66:                int     s_disk;         /* Data is on disk              */
                     67:                char    *s_sp;          /* Position in core             */
                     68:                unsigned long s_seek;   /* Seek position                */
                     69:                int     s_n;            /* Counter (count down)         */
                     70:        } x4;
                     71: } STR;
                     72: 
                     73: /*
                     74:  * Global variables.
                     75:  */
                     76: extern STR     *strp;                  /* Input stack */
                     77: 
                     78: /* end of str.h */

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.