Title: [231171] trunk/Source/_javascript_Core
- Revision
- 231171
- Author
- [email protected]
- Date
- 2018-04-30 14:38:26 -0700 (Mon, 30 Apr 2018)
Log Message
Remove unneeded exception check from String.fromCharCode
https://bugs.webkit.org/show_bug.cgi?id=185083
Reviewed by Mark Lam.
* runtime/StringConstructor.cpp:
(JSC::stringFromCharCode):
Modified Paths
Diff
Modified: trunk/Source/_javascript_Core/ChangeLog (231170 => 231171)
--- trunk/Source/_javascript_Core/ChangeLog 2018-04-30 21:17:59 UTC (rev 231170)
+++ trunk/Source/_javascript_Core/ChangeLog 2018-04-30 21:38:26 UTC (rev 231171)
@@ -1,5 +1,15 @@
2018-04-30 Keith Miller <[email protected]>
+ Remove unneeded exception check from String.fromCharCode
+ https://bugs.webkit.org/show_bug.cgi?id=185083
+
+ Reviewed by Mark Lam.
+
+ * runtime/StringConstructor.cpp:
+ (JSC::stringFromCharCode):
+
+2018-04-30 Keith Miller <[email protected]>
+
Move StructureIsImmortal to out of line flags.
https://bugs.webkit.org/show_bug.cgi?id=185101
Modified: trunk/Source/_javascript_Core/runtime/StringConstructor.cpp (231170 => 231171)
--- trunk/Source/_javascript_Core/runtime/StringConstructor.cpp 2018-04-30 21:17:59 UTC (rev 231170)
+++ trunk/Source/_javascript_Core/runtime/StringConstructor.cpp 2018-04-30 21:38:26 UTC (rev 231171)
@@ -77,9 +77,9 @@
unsigned length = exec->argumentCount();
if (LIKELY(length == 1)) {
+ scope.release();
unsigned code = exec->uncheckedArgument(0).toUInt32(exec);
- RETURN_IF_EXCEPTION(scope, encodedJSValue());
- scope.release();
+ // Not checking for an exception here is ok because jsSingleCharacterString will just fetch an unused string if there's an exception.
return JSValue::encode(jsSingleCharacterString(exec, code));
}
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes