Javascript weirdness? - Google ã°ã«ã¼ã var o1 = [], f1 = function(){ return o1; }; (new f1()) === o1; // true var o2 = 1, f2 = function(){ return o2; }; (new f2()) === o2; // false ããã£ã¦ã©ããããã¨ã ã£ã¦ã°ãï¼ ã¨ãã話ã ä¾ã«ãã£ã¦ä»æ§ãã解説ãã¦ã¿ãããã¨ã new æ¼ç®å 11.2.2 The new Operator - ECMAScript Language Specification - ECMA-262 Edition 5.1 new æ¼ç®åèªä½ã¯å®ã¯å¤§ãããã¨ã¯ãã¦ããªãã 対象ã function ã§ããã㨠対象㮠function ã« [[Construct]] å é¨ã¡ã½ãããããã㨠[[C
{{#tags}}- {{label}}
{{/tags}}