(ast)
| 113 | * @returns {t.Index} - index |
| 114 | */ |
| 115 | const getNextTypeIndex = (ast) => { |
| 116 | const typeSectionMetadata = t.getSectionMetadata(ast, "type"); |
| 117 | |
| 118 | if (typeSectionMetadata === undefined) { |
| 119 | return t.indexLiteral(0); |
| 120 | } |
| 121 | |
| 122 | return t.indexLiteral(typeSectionMetadata.vectorOfSize.value); |
| 123 | }; |
| 124 | |
| 125 | /** |
| 126 | * Get next func index |