diff --git a/kimchi/js/bindings.js b/kimchi/js/bindings.js index 05a0067d..97f26c97 100644 --- a/kimchi/js/bindings.js +++ b/kimchi/js/bindings.js @@ -470,7 +470,7 @@ var js_class_vector_to_rust_vector = function (v) { for (var i = 0; i < len; i++) { // Beware: caller may need to do finalizer things to avoid these // pointers disappearing out from under us. - res[i] = v[i].ptr; + res[i] = v[i].__wbg_ptr; } return res; }; @@ -586,7 +586,7 @@ var free_on_finalize = function (x) { // directly, but unfortunately the destructor name is some mangled internal // string generated by wasm_bindgen. For now, this is the best, // least-brittle way to free once the original class instance gets collected. - var instance_representative = x.constructor.__wrap(x.ptr); + var instance_representative = x.constructor.__wrap(x.__wbg_ptr); free_finalization_registry.register(x, instance_representative, x); return x; }; @@ -1879,7 +1879,7 @@ function index_term_of_rust(term, token_class) { // Provides: wrap function wrap(ptr, klass) { var obj = Object.create(klass.prototype); - obj.ptr = ptr; + obj.__wbg_ptr= ptr; return obj; }