1 // Copyright 2009 the Sputnik authors. All rights reserved.
2 // This code is governed by the BSD license found in the LICENSE file.
6 when String.prototype.concat([,[...]]) is called first Call ToString,
7 giving it the this value as its argument
9 description: Override toString function
13 toString: function() {
18 __instance.concat = String.prototype.concat;
20 //////////////////////////////////////////////////////////////////////////////
22 if (__instance.concat("two", x) !== "onetwoundefined") {
23 throw new Test262Error('#1: var x; __instance = {toString:function(){return "one"}}; __instance.concat = String.prototype.concat; __instance.concat("two",x) === "onetwoundefined". Actual: ' + __instance.concat("two", x));
26 //////////////////////////////////////////////////////////////////////////////