A Standard Definition of Elm?Draft version 0.4 / Rules
Rules
Each rule's address uses its name, which does not change between editions; its number may. Choose a rule for its page, with its comments and the places that refer to it.
4Static Semantics for the Core
| No. | Rule | Rule group |
|---|---|---|
| 1 | s-atexp-scon | Atomic Expressions |
| 2 | s-atexp-longvar | Atomic Expressions |
| 3 | s-atexp-longcon | Atomic Expressions |
| 4 | s-atexp-op | Atomic Expressions |
| 5 | s-atexp-unit | Atomic Expressions |
| 6 | s-atexp-tuple | Atomic Expressions |
| 7 | s-atexp-nil | Atomic Expressions |
| 8 | s-atexp-record | Atomic Expressions |
| 9 | s-atexp-update | Atomic Expressions |
| 10 | s-atexp-let | Atomic Expressions |
| 11 | s-atexp-paren | Atomic Expressions |
| 12 | s-exprow | Expression Rows |
| 13 | s-exp-atexp | Expressions |
| 14 | s-exp-app | Expressions |
| 15 | s-exp-lambda | Expressions |
| 16 | s-exp-case | Expressions |
| 17 | s-match | Matches |
| 18 | s-mrule | Match Rules |
| 19 | s-dec-group | Declarations |
| 20 | s-valbind-var | Value Bindings |
| 21 | s-valbind-pat | Value Bindings |
| 22 | s-ty-tyvar | Type Expressions |
| 23 | s-ty-rowvar | Type Expressions |
| 24 | s-ty-record | Type Expressions |
| 25 | s-ty-openrecord | Type Expressions |
| 26 | s-ty-unit | Type Expressions |
| 27 | s-ty-tuple | Type Expressions |
| 28 | s-ty-con | Type Expressions |
| 29 | s-ty-fun | Type Expressions |
| 30 | s-ty-paren | Type Expressions |
| 31 | s-tyrow | Type-expression Rows |
| 32 | s-atpat-wild | Atomic Patterns |
| 33 | s-atpat-scon | Atomic Patterns |
| 34 | s-atpat-var | Atomic Patterns |
| 35 | s-atpat-con | Atomic Patterns |
| 36 | s-atpat-unit | Atomic Patterns |
| 37 | s-atpat-tuple | Atomic Patterns |
| 38 | s-atpat-nil | Atomic Patterns |
| 39 | s-atpat-record | Atomic Patterns |
| 40 | s-atpat-paren | Atomic Patterns |
| 41 | s-patrow | Pattern Rows |
| 42 | s-pat-atpat | Patterns |
| 43 | s-pat-con | Patterns |
| 44 | s-pat-cons | Patterns |
| 45 | s-pat-as | Patterns |
5Static Semantics for Modules
| No. | Rule | Rule group |
|---|---|---|
| 46 | sm-module | Modules |
| 47 | sm-header | Headers |
| 48 | sm-imports-import | Imports |
| 49 | sm-imports-empty | Imports |
| 50 | sm-explist-all | Exposing Lists |
| 51 | sm-explist-items | Exposing Lists |
| 52 | sm-item-var | Exposing Items |
| 53 | sm-item-op | Exposing Items |
| 54 | sm-item-type | Exposing Items |
| 55 | sm-item-opentype | Exposing Items |
| 56 | sm-topdec-value | Top-level Declarations |
| 57 | sm-topdec-types | Top-level Declarations |
| 58 | sm-topdec-portout | Top-level Declarations |
| 59 | sm-topdec-portin | Top-level Declarations |
| 60 | sm-topdec-seq | Top-level Declarations |
| 61 | sm-datbind | Custom-type Bindings |
| 62 | sm-conbind | Constructor Bindings |
| 63 | sm-typbind | Alias Bindings |
| 64 | sm-typbind-record | Alias Bindings |
6Dynamic Semantics for the Core
| No. | Rule | Rule group |
|---|---|---|
| 65 | d-atexp-scon | Atomic Expressions |
| 66 | d-atexp-var | Atomic Expressions |
| 67 | d-atexp-con | Atomic Expressions |
| 68 | d-atexp-op | Atomic Expressions |
| 69 | d-atexp-unit | Atomic Expressions |
| 70 | d-atexp-tuple | Atomic Expressions |
| 71 | d-atexp-nil | Atomic Expressions |
| 72 | d-atexp-record | Atomic Expressions |
| 73 | d-atexp-update | Atomic Expressions |
| 74 | d-atexp-paren | Atomic Expressions |
| 75 | d-atexp-let | Atomic Expressions |
| 76 | d-exprow-field | Expression Rows |
| 77 | d-exp-atexp | Expressions |
| 78 | d-exp-app | Expressions |
| 79 | d-exp-lambda | Expressions |
| 80 | d-exp-case | Expressions |
| 81 | d-app-closure | Application of Values |
| 82 | d-app-con | Application of Values |
| 83 | d-app-basic-partial | Application of Values |
| 84 | d-app-basic-apply | Application of Values |
| 85 | d-match-first | Matches |
| 86 | d-match-fail | Matches |
| 87 | d-match-next | Matches |
| 88 | d-mrule-match | Match Rules |
| 89 | d-mrule-fail | Match Rules |
| 90 | d-dec-nonrec | Declarations |
| 91 | d-dec-rec | Declarations |
| 92 | d-valbind-var | Value Bindings |
| 93 | d-valbind-pat | Value Bindings |
| 94 | d-atpat-wild | Atomic Patterns |
| 95 | d-atpat-scon | Atomic Patterns |
| 96 | d-atpat-scon-fail | Atomic Patterns |
| 97 | d-atpat-var | Atomic Patterns |
| 98 | d-atpat-con | Atomic Patterns |
| 99 | d-atpat-con-fail | Atomic Patterns |
| 100 | d-atpat-unit | Atomic Patterns |
| 101 | d-atpat-tuple | Atomic Patterns |
| 102 | d-atpat-nil | Atomic Patterns |
| 103 | d-atpat-nil-fail | Atomic Patterns |
| 104 | d-atpat-record | Atomic Patterns |
| 105 | d-atpat-paren | Atomic Patterns |
| 106 | d-patrow-field | Pattern Rows |
| 107 | d-pat-atpat | Patterns |
| 108 | d-pat-con | Patterns |
| 109 | d-pat-con-fail | Patterns |
| 110 | d-pat-cons | Patterns |
| 111 | d-pat-cons-fail | Patterns |
| 112 | d-pat-as | Patterns |
7Dynamic Semantics for Modules
| No. | Rule | Rule group |
|---|---|---|
| 113 | dm-module | Modules |
| 114 | dm-header | Headers |
| 115 | dm-imports-import | Imports |
| 116 | dm-imports-empty | Imports |
| 117 | dm-explist-all | Exposing Lists |
| 118 | dm-explist-items | Exposing Lists |
| 119 | dm-expitem-var | Exposing Items |
| 120 | dm-expitem-op | Exposing Items |
| 121 | dm-expitem-alias | Exposing Items |
| 122 | dm-expitem-type | Exposing Items |
| 123 | dm-expitem-open | Exposing Items |
| 124 | dm-topdec-val | Top-level Declarations |
| 125 | dm-topdec-type | Top-level Declarations |
| 126 | dm-topdec-alias | Top-level Declarations |
| 127 | dm-topdec-port-out | Top-level Declarations |
| 128 | dm-topdec-port-in | Top-level Declarations |
| 129 | dm-topdec-seq | Top-level Declarations |
| 130 | dm-datbind | Custom-type Bindings |
| 131 | dm-conbind | Constructor Bindings |
| 132 | dm-typbind | Alias Bindings |
8Tasks, Commands, Subscriptions and Ports
| No. | Rule | Rule group |
|---|---|---|
| 133 | e-task-andthen-succeed | Task Reduction |
| 134 | e-task-andthen-fail | Task Reduction |
| 135 | e-task-onerror-fail | Task Reduction |
| 136 | e-task-onerror-succeed | Task Reduction |
| 137 | e-task-andthen-inner | Task Reduction |
| 138 | e-task-onerror-inner | Task Reduction |
| 139 | e-task-prim | Task Reduction |
| 140 | e-enc-int | Encoding |
| 141 | e-enc-float | Encoding |
| 142 | e-enc-float-null | Encoding |
| 143 | e-enc-true | Encoding |
| 144 | e-enc-false | Encoding |
| 145 | e-enc-string | Encoding |
| 146 | e-enc-bytes | Encoding |
| 147 | e-enc-unit | Encoding |
| 148 | e-enc-nothing | Encoding |
| 149 | e-enc-just | Encoding |
| 150 | e-enc-list | Encoding |
| 151 | e-enc-array | Encoding |
| 152 | e-enc-tuple | Encoding |
| 153 | e-enc-record | Encoding |
| 154 | e-enc-value | Encoding |
| 155 | e-dec-int | Decoding |
| 156 | e-dec-float | Decoding |
| 157 | e-dec-true | Decoding |
| 158 | e-dec-false | Decoding |
| 159 | e-dec-string | Decoding |
| 160 | e-dec-bytes | Decoding |
| 161 | e-dec-unit | Decoding |
| 162 | e-dec-nothing | Decoding |
| 163 | e-dec-just | Decoding |
| 164 | e-dec-list | Decoding |
| 165 | e-dec-array | Decoding |
| 166 | e-dec-tuple | Decoding |
| 167 | e-dec-record | Decoding |
| 168 | e-dec-value | Decoding |
| 169 | e-msg-task | Messages |
| 170 | e-msg-port | Messages |
| 171 | e-msg-map | Messages |
9Programs
| No. | Rule | Rule group |
|---|---|---|
| 172 | p-stat-module | Elaboration of Programs |
| 173 | p-stat-main-program | Elaboration of Programs |
| 174 | p-stat-main-view | Elaboration of Programs |
| 175 | p-dyn-module | Evaluation of Programs |
| 176 | p-dyn-main | Evaluation of Programs |
| 177 | p-program | Programs |
| 178 | p-disp-empty | Dispatch |
| 179 | p-disp-task | Dispatch |
| 180 | p-disp-out | Dispatch |
| 181 | p-disp-plat | Dispatch |
| 182 | p-init | Starting a Program |
| 183 | p-update | Transitions |
| 184 | p-proc-step | Transitions |
| 185 | p-proc-sleep | Transitions |
| 186 | p-proc-spawn | Transitions |
| 187 | p-proc-kill | Transitions |
| 188 | p-proc-message | Transitions |
| 189 | p-proc-end | Transitions |
| 190 | p-in-accept | Transitions |
| 191 | p-in-reject | Transitions |
| 192 | p-out | Transitions |
| 193 | p-wait | Transitions |
| 194 | p-platform | Transitions |
A Standard Definition of Elm? (Draft version 0.4) © Rupert Smith. The text is licensed under CC BY 4.0: share and adapt it freely, with credit and a link to the licence.