Sat, 03 Jan 2015 20:18:00 +0100
Conditionally enable double key logic according to:
private browsing mode or privacy.thirdparty.isolate preference and
implement in GetCookieStringCommon and FindCookie where it counts...
With some reservations of how to convince FindCookie users to test
condition and pass a nullptr when disabling double key logic.
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3 * License, v. 2.0. If a copy of the MPL was not distributed with this
4 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 /**
8 File Name: 15.9.5.2-2.js
9 ECMA Section: 15.9.5.2 Date.prototype.toString
10 Description:
11 This function returns a string value. The contents of the string are
12 implementation dependent, but are intended to represent the Date in a
13 convenient, human-readable form in the current time zone.
15 The toString function is not generic; it generates a runtime error if its
16 this value is not a Date object. Therefore it cannot be transferred to
17 other kinds of objects for use as a method.
20 This verifies that calling toString on an object that is not a string
21 generates a runtime error.
23 Author: christine@netscape.com
24 Date: 12 november 1997
25 */
27 var SECTION = "15.9.5.2-2";
28 var VERSION = "ECMA_1";
29 startTest();
30 var TITLE = "Date.prototype.toString";
32 writeHeaderToLog( SECTION + " "+ TITLE);
34 var OBJ = new MyObject( new Date(0) );
36 DESCRIPTION = "var OBJ = new MyObject( new Date(0) ); OBJ.toString()";
37 EXPECTED = "error";
39 new TestCase( SECTION,
40 "var OBJ = new MyObject( new Date(0) ); OBJ.toString()",
41 "error",
42 eval("OBJ.toString()") );
43 test();
45 function MyObject( value ) {
46 this.value = value;
47 this.valueOf = new Function( "return this.value" );
48 this.toString = Date.prototype.toString;
49 return this;
50 }