Changeset 204388 in webkit
- Timestamp:
- Aug 11, 2016 2:21:55 PM (8 years ago)
- Location:
- trunk
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JSTests/ChangeLog
r204387 r204388 1 2016-08-10 Mark Lam <mark.lam@apple.com> 1 2016-08-11 Mark Lam <mark.lam@apple.com> 2 3 The jsc shell's Element host constructor should throw if it fails to construct an object. 4 https://bugs.webkit.org/show_bug.cgi?id=160773 5 <rdar://problem/27328608> 6 7 Reviewed by Saam Barati. 8 9 * stress/generational-opaque-roots.js: 10 11 2016-08-11 Mark Lam <mark.lam@apple.com> 2 12 3 13 Disallow synchronous sweeping for eden GCs. -
trunk/JSTests/stress/generational-opaque-roots.js
r164935 r204388 1 1 // Tests that opaque roots behave correctly during young generation collections 2 3 try { 4 // regression test for bug 160773. This should not crash. 5 new (Element.bind()); 6 } catch(e) { 7 } 2 8 3 9 // Create the primary Root. -
trunk/Source/JavaScriptCore/ChangeLog
r204387 r204388 1 2016-08-10 Mark Lam <mark.lam@apple.com> 1 2016-08-11 Mark Lam <mark.lam@apple.com> 2 3 The jsc shell's Element host constructor should throw if it fails to construct an object. 4 https://bugs.webkit.org/show_bug.cgi?id=160773 5 <rdar://problem/27328608> 6 7 Reviewed by Saam Barati. 8 9 The Element object is a test object provided in the jsc shell for testing use only. 10 JavaScriptCore expects host constructors to either throw an error or return a 11 constructed object. Element has a host constructor that did not obey this contract. 12 As a result, the following statement will fail a RELEASE_ASSERT: 13 14 new (Element.bind()) 15 16 This is now fixed. 17 18 * jsc.cpp: 19 (functionCreateElement): 20 21 2016-08-11 Mark Lam <mark.lam@apple.com> 2 22 3 23 Disallow synchronous sweeping for eden GCs. -
trunk/Source/JavaScriptCore/jsc.cpp
r204330 r204388 1232 1232 Root* root = jsDynamicCast<Root*>(exec->argument(0)); 1233 1233 if (!root) 1234 return JSValue::encode( jsUndefined());1234 return JSValue::encode(exec->vm().throwException(exec, createError(exec, ASCIILiteral("Cannot create Element without a Root.")))); 1235 1235 return JSValue::encode(Element::create(exec->vm(), exec->lexicalGlobalObject(), root)); 1236 1236 }
Note: See TracChangeset
for help on using the changeset viewer.