Adds type knowledge to javascript objects