René Nyffenegger's collection of things on the web | |
René Nyffenegger on Oracle - Most wanted - Feedback
- Follow @renenyffenegger
|
eval [JavaScript snippet] | ||
function main() { var fourty_two = eval("29+11+2"); txt_out("fourty_two: " + fourty_two); var obj = { one : 1, two : 2, more : { banana : "yellow", ice : "cold", }, }; var obj_cloned = eval(obj.toSource()); txt_out("obj_cloned.more.banana: " + obj_cloned.more.banana); if (obj_cloned == obj) { txt_out("obj_cloned } }
See also other Javascript snippets
|