From 961cc1e8f346d52842cc116285d19eb8e71ceb2c Mon Sep 17 00:00:00 2001 From: "Alex A. Naanou" Date: Tue, 7 Aug 2018 11:14:46 +0300 Subject: [PATCH] notes... Signed-off-by: Alex A. Naanou --- diff.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/diff.js b/diff.js index 1c3f766..e7d0d66 100644 --- a/diff.js +++ b/diff.js @@ -456,16 +456,16 @@ object.makeConstructor('NUMBER', Object.assign(new LogicType(), { })) // - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -// XXX IN(A) == L iff A in L +// IN(A) == L iff A in L +// +// NOTE: since this can do a search using cmp(..) thid will be slow on +// large containers... // XXX add support for other containers... var IN = module.IN = object.makeConstructor('IN', Object.assign(new LogicType(), { __cmp__: function(obj, cmp){ var p = this.value - // XXX the problem here is that we need to both directly test and - // deep test (seatch) for the .value in obj... - // ...this may get really slow... // XXX add support for other stuff like sets and maps... // XXX make this a break-on-match and not a go-through-the-whole-thing return p in obj