blob: edccccc13265b24617f96b1a1b782a0ae2b0583e [file] [log] [blame]
// WARNING: This file is machine generated by fidlgen.
#include <handles_in_types.test.json.llcpp.h>
#include <memory>
namespace llcpp {
namespace test {
namespace name {
auto ::llcpp::test::name::UnionWithHandle::which() const -> Tag {
ZX_ASSERT(!has_invalid_tag());
switch (ordinal_) {
case Ordinal::kH:
return static_cast<Tag>(ordinal_);
default:
return Tag::kUnknown;
}
}
void ::llcpp::test::name::UnionWithHandle::SizeAndOffsetAssertionHelper() {
static_assert(sizeof(UnionWithHandle) == sizeof(fidl_xunion_t));
static_assert(offsetof(UnionWithHandle, ordinal_) ==
offsetof(fidl_xunion_t, tag));
static_assert(offsetof(UnionWithHandle, envelope_) ==
offsetof(fidl_xunion_t, envelope));
}
} // namespace name
} // namespace test
} // namespace llcpp