Files
WoW-Hybrid-gateway/native/object_update_layout_guard.hpp
praxisandClaude Fable 5.2 8e02dccb86 In-client stack: transport, session lifecycle and engine bridge
175 files, from working commit b1a079a.

Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
2026-11-19 01:32:48 +02:00

20 lines
756 B
C++

#pragma once
// Opt in only where the corresponding build target enforces this link.
// Other platforms must not acquire a dependency on an unvalidated ABI guard.
#if defined(__linux__) && (defined(__GNUC__) || defined(__clang__))
#include "gateway/object_updates.hpp"
// Include only in translation units that use LegacyObjectUpdate. The call is
// emitted in each such unit, so its layout must match the protocol parser at
// link time even when the unit consumes the record only through a destructor.
namespace {
struct ObjectUpdateLayoutGuard {
ObjectUpdateLayoutGuard() noexcept {
gateway::require_legacy_object_update_layout(nullptr);
}
};
[[maybe_unused]] const ObjectUpdateLayoutGuard object_update_layout_guard{};
} // namespace
#endif