From 49083f71bb372883f32d22758c808d9de7c73575 Mon Sep 17 00:00:00 2001 From: Matt Corallo Date: Sat, 3 Sep 2022 20:41:43 +0000 Subject: [PATCH] [TS] Update auto-generated file --- ts/structs/CommonBase.mts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ts/structs/CommonBase.mts b/ts/structs/CommonBase.mts index 8ce5766a..df2cad8e 100644 --- a/ts/structs/CommonBase.mts +++ b/ts/structs/CommonBase.mts @@ -374,7 +374,7 @@ export class CommonBase { // In TypeScript, protected means "any subclass can access parent fields on instances of itself" // To work around this, we add accessors for other instances' protected fields here. protected static add_ref_from(holder: CommonBase, referent: object) { - holder.ptrs_to.push(referent); + if (holder !== null) { holder.ptrs_to.push(referent); } } protected static get_ptr_of(o: CommonBase) { return o.ptr; -- 2.30.2