Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 94bbba49ee070b68a783d362764ad649fb723aa3
https://github.com/WebKit/WebKit/commit/94bbba49ee070b68a783d362764ad649fb723aa3
Author: Chris Dumez <[email protected]>
Date: 2026-03-10 (Tue, 10 Mar 2026)
Changed paths:
M Source/WTF/wtf/TypeTraits.h
M Source/WTF/wtf/WeakPtr.h
M Source/WTF/wtf/WeakRef.h
Log Message:
-----------
Confusing build error message when using WeakPtr<T>::get() with a T that is
not defined
https://bugs.webkit.org/show_bug.cgi?id=309537
Reviewed by Ryosuke Niwa.
Confusing build error message when using WeakPtr<T>::get() with a T that
is not defined. Instead of complaining that T is not defined, it complains
that T needs to be either ref-counted or CanMakeCheckedPtr.
This PR makes it so that it complains about T not being defined again.
* Source/WTF/wtf/TypeTraits.h:
* Source/WTF/wtf/WeakPtr.h:
(WTF::WeakPtr::get const):
(WTF::WeakPtr::operator-> const):
(WTF::WeakPtr::operator* const):
* Source/WTF/wtf/WeakRef.h:
(WTF::WeakRef::ptrAllowingHashTableEmptyValue const):
(WTF::WeakRef::ptr const):
(WTF::WeakRef::get const):
Canonical link: https://commits.webkit.org/308966@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications