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 // for-of in comprehensions does not trigger the JS 1.7 for-in destructuring special case.
3 version(170);
4 load(libdir + "asserts.js");
6 var data = [[1, 2, 3], [4]];
7 var arr = eval("[a for ([a] of data)]");
8 assertEq(arr.length, 2);
9 assertEq(arr[0], 1);
10 assertEq(arr[1], 4);
12 arr = eval("[length for ({length} of data)]");
13 assertEq(arr.length, 2);
14 assertEq(arr[0], 3);
15 assertEq(arr[1], 1);