Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: c0596157ce8fe866b1d14c2e2d7ca32204fc92a3
https://github.com/WebKit/WebKit/commit/c0596157ce8fe866b1d14c2e2d7ca32204fc92a3
Author: Chris Dumez <[email protected]>
Date: 2025-06-03 (Tue, 03 Jun 2025)
Changed paths:
M Source/JavaScriptCore/API/JSManagedValue.mm
M Source/WTF/wtf/RefPtr.h
M Source/WebCore/bindings/scripts/CodeGeneratorJS.pm
M Source/WebCore/bindings/scripts/test/JS/JSExposedStar.h
M Source/WebCore/bindings/scripts/test/JS/JSExposedToWorkerAndWindow.h
M Source/WebCore/bindings/scripts/test/JS/JSTestAsyncIterable.h
M Source/WebCore/bindings/scripts/test/JS/JSTestAsyncKeyValueIterable.h
M Source/WebCore/bindings/scripts/test/JS/JSTestCEReactions.h
M Source/WebCore/bindings/scripts/test/JS/JSTestCEReactionsStringifier.h
M Source/WebCore/bindings/scripts/test/JS/JSTestCallTracer.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestClassWithJSBuiltinConstructor.h
M Source/WebCore/bindings/scripts/test/JS/JSTestConditionalIncludes.h
M Source/WebCore/bindings/scripts/test/JS/JSTestConditionallyReadWrite.h
M Source/WebCore/bindings/scripts/test/JS/JSTestDefaultToJSON.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestDefaultToJSONFilteredByExposed.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestDelegateToSharedSyntheticAttribute.h
M Source/WebCore/bindings/scripts/test/JS/JSTestDomainSecurity.h
M Source/WebCore/bindings/scripts/test/JS/JSTestEnabledBySetting.h
M Source/WebCore/bindings/scripts/test/JS/JSTestEnabledForContext.h
M Source/WebCore/bindings/scripts/test/JS/JSTestEventConstructor.h
M Source/WebCore/bindings/scripts/test/JS/JSTestEventTarget.h
M Source/WebCore/bindings/scripts/test/JS/JSTestException.h
M Source/WebCore/bindings/scripts/test/JS/JSTestGenerateAddOpaqueRoot.h
M Source/WebCore/bindings/scripts/test/JS/JSTestGenerateIsReachable.h
M Source/WebCore/bindings/scripts/test/JS/JSTestIndexedSetterNoIdentifier.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestIndexedSetterThrowingException.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestIndexedSetterWithIdentifier.h
M Source/WebCore/bindings/scripts/test/JS/JSTestInterface.h
M Source/WebCore/bindings/scripts/test/JS/JSTestInterfaceLeadingUnderscore.h
M Source/WebCore/bindings/scripts/test/JS/JSTestIterable.h
M Source/WebCore/bindings/scripts/test/JS/JSTestLegacyFactoryFunction.h
M Source/WebCore/bindings/scripts/test/JS/JSTestLegacyNoInterfaceObject.h
M Source/WebCore/bindings/scripts/test/JS/JSTestLegacyOverrideBuiltIns.h
M Source/WebCore/bindings/scripts/test/JS/JSTestMapLike.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestMapLikeWithOverriddenOperations.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedAndIndexedSetterNoIdentifier.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedAndIndexedSetterThrowingException.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedAndIndexedSetterWithIdentifier.h
M Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterNoIdentifier.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterThrowingException.h
M Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterWithIdentifier.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedDeleterWithIndexedGetter.h
M Source/WebCore/bindings/scripts/test/JS/JSTestNamedGetterCallWith.h
M Source/WebCore/bindings/scripts/test/JS/JSTestNamedGetterNoIdentifier.h
M Source/WebCore/bindings/scripts/test/JS/JSTestNamedGetterWithIdentifier.h
M Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterNoIdentifier.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterThrowingException.h
M Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithIdentifier.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetter.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithIndexedGetterAndSetter.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithLegacyOverrideBuiltIns.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeableProperties.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestNamedSetterWithLegacyUnforgeablePropertiesAndLegacyOverrideBuiltIns.h
M Source/WebCore/bindings/scripts/test/JS/JSTestNode.h
M Source/WebCore/bindings/scripts/test/JS/JSTestObj.h
M Source/WebCore/bindings/scripts/test/JS/JSTestOperationConditional.h
M Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructors.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestOverloadedConstructorsWithSequence.h
M Source/WebCore/bindings/scripts/test/JS/JSTestPluginInterface.h
M Source/WebCore/bindings/scripts/test/JS/JSTestPromiseRejectionEvent.h
M Source/WebCore/bindings/scripts/test/JS/JSTestReadOnlyMapLike.h
M Source/WebCore/bindings/scripts/test/JS/JSTestReadOnlySetLike.h
M Source/WebCore/bindings/scripts/test/JS/JSTestReportExtraMemoryCost.h
M Source/WebCore/bindings/scripts/test/JS/JSTestScheduledAction.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.h
M Source/WebCore/bindings/scripts/test/JS/JSTestSetLike.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestSetLikeWithOverriddenOperations.h
M Source/WebCore/bindings/scripts/test/JS/JSTestStringifier.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestStringifierAnonymousOperation.h
M Source/WebCore/bindings/scripts/test/JS/JSTestStringifierNamedOperation.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestStringifierOperationImplementedAs.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestStringifierOperationNamedToString.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestStringifierReadOnlyAttribute.h
M
Source/WebCore/bindings/scripts/test/JS/JSTestStringifierReadWriteAttribute.h
M Source/WebCore/bindings/scripts/test/JS/JSTestTaggedWrapper.h
M Source/WebCore/bindings/scripts/test/JS/JSTestTypedefs.h
M Source/WebCore/page/DebugPageOverlays.cpp
M Source/WebCore/page/FocusController.cpp
M Source/WebCore/page/Page.cpp
M Source/WebCore/page/PageGroupLoadDeferrer.cpp
M Source/WebCore/page/SettingsBase.cpp
M Source/WebCore/page/scrolling/ScrollingCoordinator.cpp
M Source/WebKit/WebProcess/GPU/media/RemoteAudioDestinationProxy.cpp
M Source/WebKit/WebProcess/GPU/media/RemoteAudioSession.cpp
M Source/WebKit/WebProcess/GPU/media/RemoteImageDecoderAVFManager.cpp
M Source/WebKit/WebProcess/GPU/media/RemoteMediaPlayerManager.cpp
M Source/WebKit/WebProcess/GPU/media/RemoteRemoteCommandListener.cpp
M Source/WebKit/WebProcess/GPU/media/ios/RemoteMediaSessionHelper.cpp
M Source/WebKit/WebProcess/GPU/webrtc/LibWebRTCCodecs.cpp
M
Source/WebKit/WebProcess/InjectedBundle/API/gtk/DOM/WebKitDOMHTMLSelectElement.cpp
M Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.cpp
M Source/WebKit/WebProcess/Network/WebLoaderStrategy.cpp
M Source/WebKit/WebProcess/Plugins/PDF/UnifiedPDF/UnifiedPDFPlugin.mm
M Source/WebKit/WebProcess/WebCoreSupport/WebLocalFrameLoaderClient.cpp
M Source/WebKit/WebProcess/WebPage/FindController.cpp
M Source/WebKit/WebProcess/WebPage/IPCTestingAPI.cpp
M Source/WebKit/WebProcess/WebPage/RemoteLayerTree/GraphicsLayerCARemote.mm
M Source/WebKit/WebProcess/WebPage/RemoteLayerTree/PlatformCALayerRemote.mm
M Source/WebKit/WebProcess/WebPage/WebFoundTextRangeController.cpp
M Source/WebKit/WebProcess/WebPage/WebPage.cpp
M Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm
M Source/WebKitLegacy/WebCoreSupport/WebSocketChannel.cpp
M Source/WebKitLegacy/mac/DOM/DOMHTMLSelectElement.mm
M Source/WebKitLegacy/mac/WebCoreSupport/WebGeolocationClient.mm
M Source/WebKitLegacy/mac/WebCoreSupport/WebOpenPanelResultListener.mm
M Source/WebKitLegacy/mac/WebView/WebView.mm
Log Message:
-----------
Allow constructing a `RefPtr<T>` from a `T&` instead of requiring a `T*`
https://bugs.webkit.org/show_bug.cgi?id=293988
Reviewed by Ryosuke Niwa.
I think this makes sense as we already allow constructing a `RefPtr<T>` from a
`Ref<T>&&`,
and a `WeakPtr<T>` from a `T&`. This makes our code a little nicer and this
avoids having
the RefPtr constructor do a null check that is unnecessary (though the compiler
hopefully
optimizes it out).
I have done some adoption in this patch to show the impact and I will follow-up
to do more
adoption if this gets approved.
Canonical link: https://commits.webkit.org/295794@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes