[webkit-changes] [WebKit/WebKit] eeedf0: [JSC] add support for `Uint8Array.fromHex` and `Ui...
Devin Rousso
noreply at github.com
Mon Jul 15 06:54:54 PDT 2024
Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: eeedf04c47ffec014748b4d743f31a68f2a3f292
https://github.com/WebKit/WebKit/commit/eeedf04c47ffec014748b4d743f31a68f2a3f292
Author: Devin Rousso <hi at devinrousso.com>
Date: 2024-07-15 (Mon, 15 Jul 2024)
Changed paths:
A JSTests/stress/uint8array-fromHex.js
A JSTests/stress/uint8array-setFromHex.js
M Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj
M Source/JavaScriptCore/Sources.txt
M Source/JavaScriptCore/runtime/CommonIdentifiers.h
A Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.cpp
M Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.h
M Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructorInlines.h
M Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototype.cpp
M Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototype.h
M Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototypeInlines.h
Log Message:
-----------
[JSC] add support for `Uint8Array.fromHex` and `Uint8Array.prototype.setFromHex`
https://bugs.webkit.org/show_bug.cgi?id=275593
Reviewed by Yusuke Suzuki.
These methods will make it easier for developers to decode typed character/byte data.
Note that there are other methods in the related proposal, but for ease of reviewing they will be implemented separately.
Spec: <https://tc39.es/proposal-arraybuffer-base64/spec/>
Proposal: <https://github.com/tc39/proposal-arraybuffer-base64>
* Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.h:
* Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructorInlines.h:
(JSC::JSGenericTypedArrayViewConstructor<ViewClass>::finishCreation):
* Source/JavaScriptCore/runtime/JSGenericTypedArrayViewConstructor.cpp: Added.
(JSC::uint8ArrayConstructorFromHex):
* Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototype.h:
* Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototypeInlines.h:
(JSC::JSGenericTypedArrayViewPrototype<ViewClass>::finishCreation):
* Source/JavaScriptCore/runtime/JSGenericTypedArrayViewPrototype.cpp:
(JSC::uint8ArrayPrototypeSetFromHex):
* Source/JavaScriptCore/runtime/CommonIdentifiers.h:
Create builtin identifiers for `read` and `written`.
* Source/JavaScriptCore/JavaScriptCore.xcodeproj/project.pbxproj:
* Source/JavaScriptCore/Sources.txt:
* JSTests/stress/uint8array-fromHex.js: Added.
* JSTests/stress/uint8array-setFromHex.js: Added.
Canonical link: https://commits.webkit.org/280967@main
To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications
More information about the webkit-changes
mailing list