Crates a new descriptor for a 64-bit table. Note that 64-bit tables are part of the memory64 proposal for WebAssembly which is not standardized yet.
(element: RefType, min: u64, max: Option<u64>)
| 3101 | /// Note that 64-bit tables are part of the memory64 proposal for |
| 3102 | /// WebAssembly which is not standardized yet. |
| 3103 | pub fn new64(element: RefType, min: u64, max: Option<u64>) -> TableType { |
| 3104 | let ref_type = element.to_wasm_type(); |
| 3105 | |
| 3106 | debug_assert!( |
| 3107 | ref_type.is_canonicalized_for_runtime_usage(), |
| 3108 | "should be canonicalized for runtime usage: {ref_type:?}" |
| 3109 | ); |
| 3110 | |
| 3111 | TableType { |
| 3112 | element, |
| 3113 | ty: Table { |
| 3114 | ref_type, |
| 3115 | idx_type: IndexType::I64, |
| 3116 | limits: Limits { min, max }, |
| 3117 | }, |
| 3118 | } |
| 3119 | } |
| 3120 | |
| 3121 | /// Returns whether or not this table is a 64-bit table. |
| 3122 | /// |