Diff
Modified: trunk/Source/WebKit/ChangeLog (284709 => 284710)
--- trunk/Source/WebKit/ChangeLog 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/ChangeLog 2021-10-22 19:50:43 UTC (rev 284710)
@@ -1,3 +1,29 @@
+2021-10-22 Alex Christensen <[email protected]>
+
+ Use C++17 nested namespace syntax for WebKit::PCM
+ https://bugs.webkit.org/show_bug.cgi?id=232162
+
+ Reviewed by Yusuke Suzuki.
+
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementClientImpl.cpp:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementConnection.cpp:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDaemonClient.cpp:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDaemonClient.h:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.cpp:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.h:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDebugInfo.cpp:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDebugInfo.h:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementManagerInterface.cpp:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementManagerProxy.cpp:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementNetworkLoader.cpp:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementNetworkLoader.h:
+ * NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementStore.cpp:
+ * NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementConnectionCocoa.mm:
+ * NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementNetworkLoaderCocoa.mm:
+ * NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementXPCUtilities.h:
+ * NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementXPCUtilities.mm:
+ * Shared/EntryPointUtilities/Cocoa/Daemon/PCMDaemonConnectionSet.mm:
+
2021-10-22 Per Arne Vollan <[email protected]>
[iOS] Add required syscall
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementClientImpl.cpp (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementClientImpl.cpp 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementClientImpl.cpp 2021-10-22 19:50:43 UTC (rev 284710)
@@ -29,10 +29,8 @@
#include "NetworkProcess.h"
#include "NetworkSession.h"
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
ClientImpl::ClientImpl(NetworkSession& session, NetworkProcess& networkProcess)
: m_networkSession(session)
, m_networkProcess(networkProcess) { }
@@ -59,6 +57,4 @@
&& !m_networkSession->sessionID().isEphemeral();
}
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementConnection.cpp (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementConnection.cpp 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementConnection.cpp 2021-10-22 19:50:43 UTC (rev 284710)
@@ -28,10 +28,8 @@
#include "NetworkSession.h"
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
Connection::Connection(CString&& machServiceName, NetworkSession& networkSession)
: Daemon::ConnectionToMachService<ConnectionTraits>(WTFMove(machServiceName))
, m_networkSession(networkSession)
@@ -44,6 +42,4 @@
}
#endif
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDaemonClient.cpp (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDaemonClient.cpp 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDaemonClient.cpp 2021-10-22 19:50:43 UTC (rev 284710)
@@ -30,10 +30,8 @@
#include "PCMDaemonConnectionSet.h"
#endif
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
void DaemonClient::broadcastConsoleMessage(JSC::MessageLevel level, const String& message)
{
#if PLATFORM(COCOA)
@@ -58,6 +56,4 @@
#endif
}
-} // namespace PCM
-
} // namespace WebKit
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDaemonClient.h (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDaemonClient.h 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDaemonClient.h 2021-10-22 19:50:43 UTC (rev 284710)
@@ -29,10 +29,8 @@
#include <wtf/FastMalloc.h>
#include <wtf/WeakPtr.h>
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
class DaemonClient : public Client, public CanMakeWeakPtr<DaemonClient> {
WTF_MAKE_FAST_ALLOCATED;
void broadcastConsoleMessage(JSC::MessageLevel, const String&) final;
@@ -41,6 +39,4 @@
bool runningInDaemon() const final { return true; }
};
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.cpp (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.cpp 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.cpp 2021-10-22 19:50:43 UTC (rev 284710)
@@ -34,10 +34,8 @@
#include <WebCore/SQLiteStatementAutoResetScope.h>
#include <WebCore/SQLiteTransaction.h>
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
constexpr auto setUnattributedPrivateClickMeasurementAsExpiredQuery = "UPDATE UnattributedPrivateClickMeasurement SET timeOfAdClick = -1.0"_s;
constexpr auto insertUnattributedPrivateClickMeasurementQuery = "INSERT OR REPLACE INTO UnattributedPrivateClickMeasurement (sourceSiteDomainID, destinationSiteDomainID, "
"sourceID, timeOfAdClick, token, signature, keyID, sourceApplicationBundleID) VALUES (?, ?, ?, ?, ?, ?, ?, ?)"_s;
@@ -759,6 +757,4 @@
}
}
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.h (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.h 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDatabase.h 2021-10-22 19:50:43 UTC (rev 284710)
@@ -29,10 +29,8 @@
#include <WebCore/PrivateClickMeasurement.h>
#include <wtf/ThreadSafeRefCounted.h>
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
struct DebugInfo;
// This is created, used, and destroyed on the Store's queue.
@@ -104,6 +102,4 @@
mutable Statement m_insertObservedDomainStatement;
};
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDebugInfo.cpp (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDebugInfo.cpp 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDebugInfo.cpp 2021-10-22 19:50:43 UTC (rev 284710)
@@ -26,10 +26,8 @@
#include "config.h"
#include "PrivateClickMeasurementDebugInfo.h"
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
DebugInfo DebugInfo::isolatedCopy() const
{
return { messages.isolatedCopy() };
@@ -40,6 +38,4 @@
return { messageLevel, message.isolatedCopy() };
}
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDebugInfo.h (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDebugInfo.h 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementDebugInfo.h 2021-10-22 19:50:43 UTC (rev 284710)
@@ -28,10 +28,8 @@
#include <_javascript_Core/ConsoleTypes.h>
#include <wtf/text/WTFString.h>
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
struct DebugInfo {
struct Message {
@@ -46,6 +44,4 @@
DebugInfo isolatedCopy() const;
};
-} // namespace PCM
-
} // namespace WebKit
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementManagerInterface.cpp (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementManagerInterface.cpp 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementManagerInterface.cpp 2021-10-22 19:50:43 UTC (rev 284710)
@@ -38,10 +38,8 @@
#include "PCMDaemonConnectionSet.h"
#endif
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
namespace MessageInfo {
#define FUNCTION(mf) struct mf { static constexpr auto MemberFunction = &PrivateClickMeasurementManager::mf;
@@ -312,6 +310,4 @@
}
}
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementManagerProxy.cpp (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementManagerProxy.cpp 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementManagerProxy.cpp 2021-10-22 19:50:43 UTC (rev 284710)
@@ -31,10 +31,8 @@
#include "PrivateClickMeasurementConnection.h"
#include "WebCoreArgumentCoders.h"
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
template<MessageType messageType, typename... Args>
void ManagerProxy::sendMessage(Args&&... args) const
{
@@ -165,6 +163,4 @@
sendMessage<MessageType::AllowTLSCertificateChainForLocalPCMTesting>(certificateInfo);
}
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementNetworkLoader.cpp (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementNetworkLoader.cpp 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementNetworkLoader.cpp 2021-10-22 19:50:43 UTC (rev 284710)
@@ -30,10 +30,8 @@
#include <WebCore/ResourceError.h>
#include <WebCore/ResourceResponse.h>
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
#if !PLATFORM(COCOA)
void NetworkLoader::start(URL&&, RefPtr<JSON::Object>&&, WebCore::PrivateClickMeasurement::PcmDataCarried, Callback&& completionHandler)
{
@@ -48,6 +46,4 @@
#endif
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementNetworkLoader.h (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementNetworkLoader.h 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementNetworkLoader.h 2021-10-22 19:50:43 UTC (rev 284710)
@@ -35,10 +35,8 @@
class ResourceResponse;
}
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
class NetworkLoader {
WTF_MAKE_FAST_ALLOCATED;
public:
@@ -47,6 +45,4 @@
static void allowTLSCertificateChainForLocalPCMTesting(const WebCore::CertificateInfo&);
};
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementStore.cpp (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementStore.cpp 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/PrivateClickMeasurementStore.cpp 2021-10-22 19:50:43 UTC (rev 284710)
@@ -33,10 +33,8 @@
#include <wtf/RunLoop.h>
#include <wtf/SuspendableWorkQueue.h>
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
static Ref<SuspendableWorkQueue> sharedWorkQueue()
{
static NeverDestroyed<Ref<SuspendableWorkQueue>> queue(SuspendableWorkQueue::create("PrivateClickMeasurement Process Data Queue", WorkQueue::QOS::Utility));
@@ -188,6 +186,4 @@
});
}
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementConnectionCocoa.mm (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementConnectionCocoa.mm 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementConnectionCocoa.mm 2021-10-22 19:50:43 UTC (rev 284710)
@@ -30,10 +30,8 @@
#import "PrivateClickMeasurementXPCUtilities.h"
#import <wtf/NeverDestroyed.h>
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
void Connection::newConnectionWasInitialized() const
{
ASSERT(m_connection);
@@ -69,6 +67,4 @@
return dictionary;
}
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementNetworkLoaderCocoa.mm (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementNetworkLoaderCocoa.mm 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementNetworkLoaderCocoa.mm 2021-10-22 19:50:43 UTC (rev 284710)
@@ -75,10 +75,8 @@
@end
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
enum LoadTaskIdentifierType { };
using LoadTaskIdentifier = ObjectIdentifier<LoadTaskIdentifierType>;
static HashMap<LoadTaskIdentifier, RetainPtr<NSURLSessionDataTask>>& taskMap()
@@ -138,6 +136,4 @@
taskMap().add(identifier, task);
}
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementXPCUtilities.h (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementXPCUtilities.h 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementXPCUtilities.h 2021-10-22 19:50:43 UTC (rev 284710)
@@ -28,12 +28,8 @@
#include <wtf/Vector.h>
#include <wtf/spi/darwin/XPCSPI.h>
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
void addVersionAndEncodedMessageToDictionary(Vector<uint8_t>&&, xpc_object_t);
-} // namespace PCM
-
-} // namespace WebKit
+} // namespace WebKit::PCM
Modified: trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementXPCUtilities.mm (284709 => 284710)
--- trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementXPCUtilities.mm 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/NetworkProcess/PrivateClickMeasurement/cocoa/PrivateClickMeasurementXPCUtilities.mm 2021-10-22 19:50:43 UTC (rev 284710)
@@ -30,10 +30,8 @@
#import "PrivateClickMeasurementManagerInterface.h"
#import <wtf/OSObjectPtr.h>
-namespace WebKit {
+namespace WebKit::PCM {
-namespace PCM {
-
void addVersionAndEncodedMessageToDictionary(Vector<uint8_t>&& message, xpc_object_t dictionary)
{
ASSERT(xpc_get_type(dictionary) == XPC_TYPE_DICTIONARY);
@@ -41,6 +39,4 @@
xpc_dictionary_set_value(dictionary, PCM::protocolEncodedMessageKey, vectorToXPCData(WTFMove(message)).get());
}
-} // namespace PCM
-
} // namespace WebKit
Modified: trunk/Source/WebKit/Shared/EntryPointUtilities/Cocoa/Daemon/PCMDaemonConnectionSet.mm (284709 => 284710)
--- trunk/Source/WebKit/Shared/EntryPointUtilities/Cocoa/Daemon/PCMDaemonConnectionSet.mm 2021-10-22 19:22:53 UTC (rev 284709)
+++ trunk/Source/WebKit/Shared/EntryPointUtilities/Cocoa/Daemon/PCMDaemonConnectionSet.mm 2021-10-22 19:50:43 UTC (rev 284710)
@@ -31,8 +31,7 @@
#import <wtf/OSObjectPtr.h>
#import <wtf/RunLoop.h>
-namespace WebKit {
-namespace PCM {
+namespace WebKit::PCM {
DaemonConnectionSet& DaemonConnectionSet::singleton()
{
@@ -91,5 +90,4 @@
xpc_connection_send_message(connection.get(), dictionary.get());
}
-} // namespace PCM
-} // namespace WebKit
+} // namespace WebKit::PCM