Message from JavaScript discussions

May 2017

— Still works, but I will fix just because it bothers me to look at it, haha, it's in typeCheck

— 

TrgwiiLappy:~/.node_modules$ node set.perf.js
validating arrset.js...
validating set.js...
validating stringSet.js...
/home/trgwii/.node_modules/set.test.js:7
const set = new Set();
^

TypeError: Set is not a constructor

— Well

— Oh...

— Validating stringSet.js...
{ H: { '5': [ 'Hello' ] } }
{ H: 1, e: 1, l: 2, o: 1 }
{ H: { '4': [ 'Hell' ], '5': [ 'Hello' ] } }
{ H: 2, e: 2, l: 4, o: 1 }
{ H: { '4': [ 'Hell' ], '5': [ 'Hello' ] },
T: { '4': [ 'True' ] } }
{ H: 2, e: 3, l: 4, o: 1, T: 1, r: 1, u: 1 }
{ H: { '4': [ 'Hell' ] }, T: { '4': [ 'True' ] } }
{ H: 1, e: 2, l: 2, T: 1, r: 1, u: 1 }

assert.js:81
throw new assert.AssertionError({
^
AssertionError: delete returns falsy for values in the set

Message permanent page

— Fixed that too

— /home/trgwii/.node_modules/sets/stringSet.js:8
throw new errorType(message);
^

TypeError: Parameter 1 must be of type String.

Message permanent page

— Interesting

— Strange that this doesn't happen in validation

— Something is messing up here

— Hmm

— I only EVER call add, has or delete with
String(Math.random()).split('.')[1] as the only argument