From 741bc131353eb856022d66252309de23a0873fc7 Mon Sep 17 00:00:00 2001 From: Stephen Blott Date: Mon, 21 Mar 2016 12:30:57 +0000 Subject: Simplify singleton handling. While working on the visual-mode code, it became apparent that our current "singleton" implementation is unnecessarily complicated. This simplifies it. The keys are now required to be strings. (Previously, they could be any object; which meant we needed to gove objects an identity. All of which was complicated.) --- tests/dom_tests/dom_tests.coffee | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/dom_tests/dom_tests.coffee b/tests/dom_tests/dom_tests.coffee index dad4def9..979500f5 100644 --- a/tests/dom_tests/dom_tests.coffee +++ b/tests/dom_tests/dom_tests.coffee @@ -744,7 +744,7 @@ context "Mode utilities", count = 0 class Test extends Mode - constructor: -> count += 1; super singleton: Test + constructor: -> count += 1; super singleton: "test" exit: -> count -= 1; super() assert.isTrue count == 0 -- cgit v1.2.3