/// <summary> /// Writes these resizable limits to the given WebAssembly file writer. /// </summary> /// <param name="writer">The WebAssembly file writer.</param> public void WriteTo(BinaryWasmWriter writer) { writer.WriteVarUInt1(HasMaximum); writer.WriteVarUInt32(Initial); if (HasMaximum) { writer.WriteVarUInt32(Maximum.Value); } }
/// <summary> /// Writes this global variable type to the given WebAssembly writer. /// </summary> /// <param name="writer">The WebAssembly writer to use.</param> public void WriteTo(BinaryWasmWriter writer) { writer.WriteWasmValueType(ContentType); writer.WriteVarUInt1(IsMutable); }