Change DefaultString and DefaultNumber to match the spec required behavior.
authorlrn@chromium.org <lrn@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Thu, 16 Dec 2010 12:49:55 +0000 (12:49 +0000)
committerlrn@chromium.org <lrn@chromium.org@ce2b1a6d-e550-0410-aec6-3dcde31c8c00>
Thu, 16 Dec 2010 12:49:55 +0000 (12:49 +0000)
commitb20f0968fac01d6336beae55e30fdffbcad2fbcb
tree30021457927a7464aa939c53d3883161017f243d
parent75d5ad65c41a5394895df8029a5724f619d30536
Change DefaultString and DefaultNumber to match the spec required behavior.

Previously it did two reads of the .toString and .valueOf properties where
only one was allowed.

Review URL: http://codereview.chromium.org/5950001

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@6047 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
src/runtime.js
test/mjsunit/object-toprimitive.js [new file with mode: 0644]