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

📄 pl3.output

📁 简介:PL0语言是pascal语言的一个子集。编译VC工程之前
💻 OUTPUT
📖 第 1 页 / 共 3 页
字号:

    relation_opr  ->  '#' .   (rule 62)

    $default	reduce using rule 62 (relation_opr)



state 90

    cond  ->  expression relation_opr . expression   (rule 58)

    '+' 	shift, and go to state 59
    '-' 	shift, and go to state 60

    $default	reduce using rule 69 (sign)

    expression	go to state 111
    sign	go to state 63



state 91

    expression  ->  expression add_opr . term   (rule 66)

    LEGAL_ID	shift, and go to state 7
    NUMBER	shift, and go to state 92
    '(' 	shift, and go to state 93

    id  	go to state 41
    var_ref	go to state 94
    term	go to state 112
    factor	go to state 96



state 92

    factor  ->  NUMBER .   (rule 77)

    $default	reduce using rule 77 (factor)



state 93

    factor  ->  '(' . expression ')'   (rule 78)

    '+' 	shift, and go to state 59
    '-' 	shift, and go to state 60

    $default	reduce using rule 69 (sign)

    expression	go to state 113
    sign	go to state 63



state 94

    factor  ->  var_ref .   (rule 76)

    $default	reduce using rule 76 (factor)



state 95

    expression  ->  sign term .   (rule 65)
    term  ->  term . multi_opr factor   (rule 75)

    '*' 	shift, and go to state 114
    '/' 	shift, and go to state 115

    $default	reduce using rule 65 (expression)

    multi_opr	go to state 116



state 96

    term  ->  factor .   (rule 74)

    $default	reduce using rule 74 (term)



state 97

    var_ref  ->  id '(' expression . ')'   (rule 50)
    expression  ->  expression . add_opr term   (rule 66)

    '+' 	shift, and go to state 84
    '-' 	shift, and go to state 85
    ')' 	shift, and go to state 117

    add_opr	go to state 91



state 98

    Cstmt  ->  var_ref COLEQ expression .   (rule 33)
    expression  ->  expression . add_opr term   (rule 66)

    '+' 	shift, and go to state 84
    '-' 	shift, and go to state 85

    $default	reduce using rule 33 (Cstmt)

    add_opr	go to state 91



state 99

    procedure_head  ->  id @4 '(' para_list . ')' ';'   (rule 24)
    para_list  ->  para_list . ',' id   (rule 26)

    ',' 	shift, and go to state 118
    ')' 	shift, and go to state 119



state 100

    para_list  ->  id .   (rule 25)

    $default	reduce using rule 25 (para_list)



state 101

    statement_list  ->  statement_list ';' statement .   (rule 46)

    $default	reduce using rule 46 (statement_list)



state 102

    Cstmt  ->  REPEAT tmp_cx statement UNTIL . cond   (rule 40)

    ODD 	shift, and go to state 58
    '+' 	shift, and go to state 59
    '-' 	shift, and go to state 60

    $default	reduce using rule 69 (sign)

    cond	go to state 120
    expression	go to state 62
    sign	go to state 63



state 103

    Cstmt  ->  WHILE tmp_cx cond tmp_jpc . DO Cstmt   (rule 39)
    Ostmt  ->  WHILE tmp_cx cond tmp_jpc . DO Ostmt   (rule 44)

    DO  	shift, and go to state 121



state 104

    arguments  ->  '(' expression_list . ')'   (rule 48)
    expression_list  ->  expression_list . ',' expression   (rule 54)

    ',' 	shift, and go to state 122
    ')' 	shift, and go to state 123



state 105

    expression_list  ->  expression .   (rule 53)
    expression  ->  expression . add_opr term   (rule 66)

    '+' 	shift, and go to state 84
    '-' 	shift, and go to state 85

    $default	reduce using rule 53 (expression_list)

    add_opr	go to state 91



state 106

    read_list  ->  read_list ',' . var_ref   (rule 52)

    LEGAL_ID	shift, and go to state 7

    id  	go to state 41
    var_ref	go to state 124



state 107

    Cstmt  ->  READ '(' read_list ')' .   (rule 37)

    $default	reduce using rule 37 (Cstmt)



state 108

    write_list  ->  write_list ',' . expression   (rule 56)

    '+' 	shift, and go to state 59
    '-' 	shift, and go to state 60

    $default	reduce using rule 69 (sign)

    expression	go to state 125
    sign	go to state 63



state 109

    Cstmt  ->  WRITE '(' write_list ')' .   (rule 38)

    $default	reduce using rule 38 (Cstmt)



state 110

    Cstmt  ->  IF cond THEN tmp_jpc . Cstmt tmp_else ELSE Cstmt   (rule 34)
    Ostmt  ->  IF cond THEN tmp_jpc . statement   (rule 42)
    Ostmt  ->  IF cond THEN tmp_jpc . Cstmt tmp_else ELSE Ostmt   (rule 43)

    BEGINSYM	shift, and go to state 34
    REPEAT	shift, and go to state 35
    WHILE	shift, and go to state 36
    CALL	shift, and go to state 37
    READ	shift, and go to state 38
    WRITE	shift, and go to state 39
    LEGAL_ID	shift, and go to state 7
    IF  	shift, and go to state 40

    $default	reduce using rule 41 (Cstmt)

    id  	go to state 41
    statement	go to state 126
    Cstmt	go to state 127
    Ostmt	go to state 44
    var_ref	go to state 45



state 111

    cond  ->  expression relation_opr expression .   (rule 58)
    expression  ->  expression . add_opr term   (rule 66)

    '+' 	shift, and go to state 84
    '-' 	shift, and go to state 85

    $default	reduce using rule 58 (cond)

    add_opr	go to state 91



state 112

    expression  ->  expression add_opr term .   (rule 66)
    term  ->  term . multi_opr factor   (rule 75)

    '*' 	shift, and go to state 114
    '/' 	shift, and go to state 115

    $default	reduce using rule 66 (expression)

    multi_opr	go to state 116



state 113

    expression  ->  expression . add_opr term   (rule 66)
    factor  ->  '(' expression . ')'   (rule 78)

    '+' 	shift, and go to state 84
    '-' 	shift, and go to state 85
    ')' 	shift, and go to state 128

    add_opr	go to state 91



state 114

    multi_opr  ->  '*' .   (rule 72)

    $default	reduce using rule 72 (multi_opr)



state 115

    multi_opr  ->  '/' .   (rule 73)

    $default	reduce using rule 73 (multi_opr)



state 116

    term  ->  term multi_opr . factor   (rule 75)

    LEGAL_ID	shift, and go to state 7
    NUMBER	shift, and go to state 92
    '(' 	shift, and go to state 93

    id  	go to state 41
    var_ref	go to state 94
    factor	go to state 129



state 117

    var_ref  ->  id '(' expression ')' .   (rule 50)

    $default	reduce using rule 50 (var_ref)



state 118

    para_list  ->  para_list ',' . id   (rule 26)

    LEGAL_ID	shift, and go to state 7

    id  	go to state 130



state 119

    procedure_head  ->  id @4 '(' para_list ')' . ';'   (rule 24)

    ';' 	shift, and go to state 131



state 120

    Cstmt  ->  REPEAT tmp_cx statement UNTIL cond .   (rule 40)

    $default	reduce using rule 40 (Cstmt)



state 121

    Cstmt  ->  WHILE tmp_cx cond tmp_jpc DO . Cstmt   (rule 39)
    Ostmt  ->  WHILE tmp_cx cond tmp_jpc DO . Ostmt   (rule 44)

    BEGINSYM	shift, and go to state 34
    REPEAT	shift, and go to state 35
    WHILE	shift, and go to state 36
    CALL	shift, and go to state 37
    READ	shift, and go to state 38
    WRITE	shift, and go to state 39
    LEGAL_ID	shift, and go to state 7
    IF  	shift, and go to state 40

    $default	reduce using rule 41 (Cstmt)

    id  	go to state 41
    Cstmt	go to state 132
    Ostmt	go to state 133
    var_ref	go to state 45



state 122

    expression_list  ->  expression_list ',' . expression   (rule 54)

    '+' 	shift, and go to state 59
    '-' 	shift, and go to state 60

    $default	reduce using rule 69 (sign)

    expression	go to state 134
    sign	go to state 63



state 123

    arguments  ->  '(' expression_list ')' .   (rule 48)

    $default	reduce using rule 48 (arguments)



state 124

    read_list  ->  read_list ',' var_ref .   (rule 52)

    $default	reduce using rule 52 (read_list)



state 125

    write_list  ->  write_list ',' expression .   (rule 56)
    expression  ->  expression . add_opr term   (rule 66)

    '+' 	shift, and go to state 84
    '-' 	shift, and go to state 85

    $default	reduce using rule 56 (write_list)

    add_opr	go to state 91



state 126

    Ostmt  ->  IF cond THEN tmp_jpc statement .   (rule 42)

    $default	reduce using rule 42 (Ostmt)



state 127

    statement  ->  Cstmt .   (rule 31)
    Cstmt  ->  IF cond THEN tmp_jpc Cstmt . tmp_else ELSE Cstmt   (rule 34)
    Ostmt  ->  IF cond THEN tmp_jpc Cstmt . tmp_else ELSE Ostmt   (rule 43)

    ELSE	reduce using rule 30 (tmp_else)
    $default	reduce using rule 31 (statement)
    tmp_else	go to state 135



state 128

    factor  ->  '(' expression ')' .   (rule 78)

    $default	reduce using rule 78 (factor)



state 129

    term  ->  term multi_opr factor .   (rule 75)

    $default	reduce using rule 75 (term)



state 130

    para_list  ->  para_list ',' id .   (rule 26)

    $default	reduce using rule 26 (para_list)



state 131

    procedure_head  ->  id @4 '(' para_list ')' ';' .   (rule 24)

    $default	reduce using rule 24 (procedure_head)



state 132

    Cstmt  ->  WHILE tmp_cx cond tmp_jpc DO Cstmt .   (rule 39)

    $default	reduce using rule 39 (Cstmt)



state 133

    Ostmt  ->  WHILE tmp_cx cond tmp_jpc DO Ostmt .   (rule 44)

    $default	reduce using rule 44 (Ostmt)



state 134

    expression_list  ->  expression_list ',' expression .   (rule 54)
    expression  ->  expression . add_opr term   (rule 66)

    '+' 	shift, and go to state 84
    '-' 	shift, and go to state 85

    $default	reduce using rule 54 (expression_list)

    add_opr	go to state 91



state 135

    Cstmt  ->  IF cond THEN tmp_jpc Cstmt tmp_else . ELSE Cstmt   (rule 34)
    Ostmt  ->  IF cond THEN tmp_jpc Cstmt tmp_else . ELSE Ostmt   (rule 43)

    ELSE	shift, and go to state 136



state 136

    Cstmt  ->  IF cond THEN tmp_jpc Cstmt tmp_else ELSE . Cstmt   (rule 34)
    Ostmt  ->  IF cond THEN tmp_jpc Cstmt tmp_else ELSE . Ostmt   (rule 43)

    BEGINSYM	shift, and go to state 34
    REPEAT	shift, and go to state 35
    WHILE	shift, and go to state 36
    CALL	shift, and go to state 37
    READ	shift, and go to state 38
    WRITE	shift, and go to state 39
    LEGAL_ID	shift, and go to state 7
    IF  	shift, and go to state 40

    $default	reduce using rule 41 (Cstmt)

    id  	go to state 41
    Cstmt	go to state 137
    Ostmt	go to state 138
    var_ref	go to state 45



state 137

    Cstmt  ->  IF cond THEN tmp_jpc Cstmt tmp_else ELSE Cstmt .   (rule 34)

    $default	reduce using rule 34 (Cstmt)



state 138

    Ostmt  ->  IF cond THEN tmp_jpc Cstmt tmp_else ELSE Ostmt .   (rule 43)

    $default	reduce using rule 43 (Ostmt)



state 139

    $   	go to state 140



state 140

    $   	go to state 141



state 141

    $default	accept


⌨️ 快捷键说明

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