⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 2.output

📁 打开2.tab.c编译运行
💻 OUTPUT
📖 第 1 页 / 共 3 页
字号:
state 22

    Statement  ->  ReadStatement .   (rule 25)

    $default	reduce using rule 25 (Statement)



state 23

    Statement  ->  WriteStatement .   (rule 26)

    $default	reduce using rule 26 (Statement)



state 24

    Condition  ->  ODD . Expression   (rule 33)

    ADD 	shift, and go to state 25
    MINUS	shift, and go to state 26
    LPARENTHESES	shift, and go to state 27
    NOSIGNINTEGER	shift, and go to state 28
    IDENT	shift, and go to state 29

    Expression	go to state 57
    TermList	go to state 32
    Term	go to state 33
    GeneList	go to state 34
    Gene	go to state 35



state 25

    Expression  ->  ADD . TermList   (rule 35)

    LPARENTHESES	shift, and go to state 27
    NOSIGNINTEGER	shift, and go to state 28
    IDENT	shift, and go to state 29

    TermList	go to state 58
    Term	go to state 33
    GeneList	go to state 34
    Gene	go to state 35



state 26

    Expression  ->  MINUS . TermList   (rule 36)

    LPARENTHESES	shift, and go to state 27
    NOSIGNINTEGER	shift, and go to state 28
    IDENT	shift, and go to state 29

    TermList	go to state 59
    Term	go to state 33
    GeneList	go to state 34
    Gene	go to state 35



state 27

    Gene  ->  LPARENTHESES . Expression RPARENTHESES   (rule 47)

    ADD 	shift, and go to state 25
    MINUS	shift, and go to state 26
    LPARENTHESES	shift, and go to state 27
    NOSIGNINTEGER	shift, and go to state 28
    IDENT	shift, and go to state 29

    Expression	go to state 60
    TermList	go to state 32
    Term	go to state 33
    GeneList	go to state 34
    Gene	go to state 35



state 28

    Gene  ->  NOSIGNINTEGER .   (rule 46)

    $default	reduce using rule 46 (Gene)



state 29

    Gene  ->  IDENT .   (rule 45)

    $default	reduce using rule 45 (Gene)



state 30

    ConditionStatement  ->  IF Condition . THEN Statement   (rule 34)

    THEN	shift, and go to state 61



state 31

    Condition  ->  Expression . RelationOperator Expression   (rule 32)

    EQUAL	shift, and go to state 62
    UNEQUAL	shift, and go to state 63
    LESS	shift, and go to state 64
    LESSEQUAL	shift, and go to state 65
    MORE	shift, and go to state 66
    MOREEQUAL	shift, and go to state 67

    RelationOperator	go to state 68



state 32

    Expression  ->  TermList .   (rule 37)
    TermList  ->  TermList . ADD Term   (rule 39)
    TermList  ->  TermList . MINUS Term   (rule 40)

    ADD 	shift, and go to state 69
    MINUS	shift, and go to state 70

    $default	reduce using rule 37 (Expression)



state 33

    TermList  ->  Term .   (rule 38)

    $default	reduce using rule 38 (TermList)



state 34

    Term  ->  GeneList .   (rule 41)
    GeneList  ->  GeneList . MULTIPLY Gene   (rule 43)
    GeneList  ->  GeneList . DIVIDE Gene   (rule 44)

    MULTIPLY	shift, and go to state 71
    DIVIDE	shift, and go to state 72

    $default	reduce using rule 41 (Term)



state 35

    GeneList  ->  Gene .   (rule 42)

    $default	reduce using rule 42 (GeneList)



state 36

    WhileStatement  ->  WHILE Condition . DO Statement   (rule 54)

    DO  	shift, and go to state 73



state 37

    ReadStatement  ->  READ LPARENTHESES . IdentList RPARENTHESES   (rule 56)

    IDENT	shift, and go to state 45

    IdentList	go to state 74



state 38

    WriteStatement  ->  WRITE LPARENTHESES . ExpressionList RPARENTHESES   (rule 57)

    ADD 	shift, and go to state 25
    MINUS	shift, and go to state 26
    LPARENTHESES	shift, and go to state 27
    NOSIGNINTEGER	shift, and go to state 28
    IDENT	shift, and go to state 29

    Expression	go to state 75
    TermList	go to state 32
    Term	go to state 33
    GeneList	go to state 34
    Gene	go to state 35
    ExpressionList	go to state 76



state 39

    ProcedureCallStatement  ->  CALL IDENT .   (rule 55)

    $default	reduce using rule 55 (ProcedureCallStatement)



state 40

    StatementList  ->  Statement .   (rule 30)

    $default	reduce using rule 30 (StatementList)



state 41

    ComplexStatement  ->  BEGIN StatementList . END   (rule 29)
    StatementList  ->  StatementList . SEMICOLON Statement   (rule 31)

    END 	shift, and go to state 77
    SEMICOLON	shift, and go to state 78



state 42

    ConstDefination  ->  IDENT . EVALUATE NOSIGNINTEGER   (rule 13)

    EVALUATE	shift, and go to state 79



state 43

    ConstantDeclaration  ->  CONST ConstList . SEMICOLON   (rule 10)
    ConstList  ->  ConstList . COMMA ConstDefination   (rule 12)

    COMMA	shift, and go to state 80
    SEMICOLON	shift, and go to state 81



state 44

    ConstList  ->  ConstDefination .   (rule 11)

    $default	reduce using rule 11 (ConstList)



state 45

    IdentList  ->  IDENT .   (rule 15)

    $default	reduce using rule 15 (IdentList)



state 46

    VariableDeclaration  ->  VAR IdentList . SEMICOLON   (rule 14)
    IdentList  ->  IdentList . COMMA IDENT   (rule 16)

    COMMA	shift, and go to state 82
    SEMICOLON	shift, and go to state 83



state 47

    ProcedureHead  ->  PROCEDURE IDENT . SEMICOLON   (rule 19)

    SEMICOLON	shift, and go to state 84



state 48

    EvaluateStatement  ->  IDENT EVALUATE . Expression   (rule 28)

    ADD 	shift, and go to state 25
    MINUS	shift, and go to state 26
    LPARENTHESES	shift, and go to state 27
    NOSIGNINTEGER	shift, and go to state 28
    IDENT	shift, and go to state 29

    Expression	go to state 85
    TermList	go to state 32
    Term	go to state 33
    GeneList	go to state 34
    Gene	go to state 35



state 49

    Program  ->  PartialProgram DOT .   (rule 1)

    $default	reduce using rule 1 (Program)



state 50

    PartialProgram  ->  ConstantDeclaration VariableDeclaration . ProcedureDeclaration Statement   (rule 2)
    PartialProgram  ->  ConstantDeclaration VariableDeclaration . Statement   (rule 5)

    IF  	shift, and go to state 1
    WHILE	shift, and go to state 2
    READ	shift, and go to state 3
    WRITE	shift, and go to state 4
    CALL	shift, and go to state 5
    BEGIN	shift, and go to state 6
    PROCEDURE	shift, and go to state 9
    IDENT	shift, and go to state 10

    $default	reduce using rule 27 (Statement)

    ProcedureDeclaration	go to state 86
    ProcedureHead	go to state 15
    Statement	go to state 87
    EvaluateStatement	go to state 17
    ComplexStatement	go to state 18
    ConditionStatement	go to state 19
    WhileStatement	go to state 20
    ProcedureCallStatement	go to state 21
    ReadStatement	go to state 22
    WriteStatement	go to state 23



state 51

    PartialProgram  ->  ConstantDeclaration ProcedureDeclaration . Statement   (rule 4)

    IF  	shift, and go to state 1
    WHILE	shift, and go to state 2
    READ	shift, and go to state 3
    WRITE	shift, and go to state 4
    CALL	shift, and go to state 5
    BEGIN	shift, and go to state 6
    IDENT	shift, and go to state 10

    $default	reduce using rule 27 (Statement)

    Statement	go to state 88
    EvaluateStatement	go to state 17
    ComplexStatement	go to state 18
    ConditionStatement	go to state 19
    WhileStatement	go to state 20
    ProcedureCallStatement	go to state 21
    ReadStatement	go to state 22
    WriteStatement	go to state 23



state 52

    PartialProgram  ->  ConstantDeclaration Statement .   (rule 6)

    $default	reduce using rule 6 (PartialProgram)



state 53

    PartialProgram  ->  VariableDeclaration ProcedureDeclaration . Statement   (rule 3)

    IF  	shift, and go to state 1
    WHILE	shift, and go to state 2
    READ	shift, and go to state 3
    WRITE	shift, and go to state 4
    CALL	shift, and go to state 5
    BEGIN	shift, and go to state 6
    IDENT	shift, and go to state 10

    $default	reduce using rule 27 (Statement)

    Statement	go to state 89
    EvaluateStatement	go to state 17
    ComplexStatement	go to state 18
    ConditionStatement	go to state 19
    WhileStatement	go to state 20
    ProcedureCallStatement	go to state 21
    ReadStatement	go to state 22
    WriteStatement	go to state 23



state 54

    PartialProgram  ->  VariableDeclaration Statement .   (rule 7)

    $default	reduce using rule 7 (PartialProgram)



state 55

    PartialProgram  ->  ProcedureDeclaration Statement .   (rule 8)

    $default	reduce using rule 8 (PartialProgram)



state 56

    ProcedureDeclaration  ->  ProcedureHead PartialProgram . SEMICOLON ProcedureDeclaration SEMICOLON   (rule 17)
    ProcedureDeclaration  ->  ProcedureHead PartialProgram . SEMICOLON   (rule 18)

    SEMICOLON	shift, and go to state 90



state 57

    Condition  ->  ODD Expression .   (rule 33)

    $default	reduce using rule 33 (Condition)



state 58

    Expression  ->  ADD TermList .   (rule 35)
    TermList  ->  TermList . ADD Term   (rule 39)
    TermList  ->  TermList . MINUS Term   (rule 40)

    ADD 	shift, and go to state 69
    MINUS	shift, and go to state 70

    $default	reduce using rule 35 (Expression)



state 59

    Expression  ->  MINUS TermList .   (rule 36)
    TermList  ->  TermList . ADD Term   (rule 39)
    TermList  ->  TermList . MINUS Term   (rule 40)

    ADD 	shift, and go to state 69
    MINUS	shift, and go to state 70

    $default	reduce using rule 36 (Expression)



state 60

    Gene  ->  LPARENTHESES Expression . RPARENTHESES   (rule 47)

    RPARENTHESES	shift, and go to state 91



state 61

    ConditionStatement  ->  IF Condition THEN . Statement   (rule 34)

    IF  	shift, and go to state 1
    WHILE	shift, and go to state 2
    READ	shift, and go to state 3
    WRITE	shift, and go to state 4
    CALL	shift, and go to state 5
    BEGIN	shift, and go to state 6
    IDENT	shift, and go to state 10

    $default	reduce using rule 27 (Statement)

    Statement	go to state 92
    EvaluateStatement	go to state 17
    ComplexStatement	go to state 18
    ConditionStatement	go to state 19
    WhileStatement	go to state 20
    ProcedureCallStatement	go to state 21
    ReadStatement	go to state 22
    WriteStatement	go to state 23



state 62

    RelationOperator  ->  EQUAL .   (rule 48)

    $default	reduce using rule 48 (RelationOperator)



state 63

    RelationOperator  ->  UNEQUAL .   (rule 49)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -