philbooth/safemap.js — pull request #2 by vbogdanov (2013-09-13 14:54:15+00:00)
Title: clear bug fix and two more public methods

Two more public methods are added:
size():integer returning the number of entries in the map
forEach(callback) iterating over the entries.
callback should be a function and is passed key and value as arguments. Invoked once for each entry.

clear() had a bug - it did not remove '__proto__' key and value.