Skip to content

Commit 0134485

Browse files
authored
Merge pull request #36 from WebAssembly/add-core-type-to-instancedecl
Add <core:type> to <componentdecl>
2 parents 8c5edc0 + 051e5bf commit 0134485

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

design/mvp/Binary.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -183,11 +183,12 @@ param ::= 0x00 t:<valtype> => (param t)
183183
| 0x01 n:<name> t:<valtype> => (param n t)
184184
componenttype ::= 0x41 cd*:vec(<componentdecl>) => (component cd*)
185185
instancetype ::= 0x42 id*:vec(<instancedecl>) => (instance id*)
186-
componentdecl ::= 0x00 id:<importdecl> => id
186+
componentdecl ::= 0x03 id:<importdecl> => id
187187
| id:<instancedecl> => id
188-
instancedecl ::= 0x01 t:<type> => t
188+
instancedecl ::= 0x00 t:<core:type> => t
189+
| 0x01 t:<type> => t
189190
| 0x02 a:<alias> => a
190-
| 0x03 ed:<exportdecl> => ed
191+
| 0x04 ed:<exportdecl> => ed
191192
importdecl ::= n:<name> ed:<externdesc> => (import n ed)
192193
exportdecl ::= n:<name> ed:<externdesc> => (export n ed)
193194
externdesc ::= 0x00 0x11 i:<core:typeidx> => (core module (type i))

design/mvp/Explainer.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -430,7 +430,8 @@ componenttype ::= (component <componentdecl>*)
430430
instancetype ::= (instance <instancedecl>*)
431431
componentdecl ::= <importdecl>
432432
| <instancedecl>
433-
instancedecl ::= <type>
433+
instancedecl ::= core-prefix(<core:type>)
434+
| <type>
434435
| <alias>
435436
| <exportdecl>
436437
importdecl ::= (import <name> bind-id(<externdesc>))

0 commit comments

Comments
 (0)