Annotation of 3BSD/cmd/pxp/yyseman.c, revision 1.1

1.1     ! root        1: /* Copyright (c) 1979 Regents of the University of California */
        !             2: #
        !             3: /*
        !             4:  * pi - Pascal interpreter code translator
        !             5:  *
        !             6:  * Charles Haley, Bill Joy UCB
        !             7:  * Version 1.2 January 1979
        !             8:  *
        !             9:  *
        !            10:  * pxp - Pascal execution profiler
        !            11:  *
        !            12:  * Bill Joy UCB
        !            13:  * Version 1.2 January 1979
        !            14:  */
        !            15: 
        !            16: #include "0.h"
        !            17: #include "yy.h"
        !            18: 
        !            19: /*
        !            20:  * Assign semantics to a generated token
        !            21:  *
        !            22:  * Most terminals have a semantic value the current
        !            23:  * input line.  If they are generated they are flagged
        !            24:  * by having this number negated.
        !            25:  *
        !            26:  * The terminals which have true semantics such
        !            27:  * as identifiers and strings are instead given
        !            28:  * semantic value NIL here - we do not attempt
        !            29:  * to do repair, e.g. by giving generated integers
        !            30:  * the value 1, etc.
        !            31:  */
        !            32: nullsem(ch)
        !            33:        int ch;
        !            34: {
        !            35: 
        !            36:        switch (ch) {
        !            37:                case YID:
        !            38:                case YINT:
        !            39:                case YNUMB:
        !            40:                case YBINT:
        !            41:                case YSTRING:
        !            42:                        return (NIL);
        !            43:                default:
        !            44:                        return (-yyeline);
        !            45:        }
        !            46: }

unix.superglobalmegacorp.com

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