From de7bb5b5fe55fe562361df6eeed61d970929c936 Mon Sep 17 00:00:00 2001 From: Martin Aeschlimann Date: Tue, 11 Aug 2020 16:23:57 +0200 Subject: [PATCH] tokenClassificationRegistry.ts: Use Object.create(null) --- src/vs/platform/theme/common/tokenClassificationRegistry.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/vs/platform/theme/common/tokenClassificationRegistry.ts b/src/vs/platform/theme/common/tokenClassificationRegistry.ts index e8bbd9403be..ab705dbcab3 100644 --- a/src/vs/platform/theme/common/tokenClassificationRegistry.ts +++ b/src/vs/platform/theme/common/tokenClassificationRegistry.ts @@ -312,8 +312,8 @@ class TokenClassificationRegistry implements ITokenClassificationRegistry { }; constructor() { - this.tokenTypeById = {}; - this.tokenModifierById = {}; + this.tokenTypeById = Object.create(null); + this.tokenModifierById = Object.create(null); this.typeHierarchy = Object.create(null); } -- GitLab