[Serialization] @execution attribute should serialize behavior (not kind)

The kind is serialize separately, the attribute record itself should
store execution behavior kind instead.
This commit is contained in:
Pavel Yaskevich
2025-01-22 17:49:26 -08:00
parent 76d1ea3fd5
commit 0d42aad92a

View File

@@ -2894,8 +2894,9 @@ class Serializer::DeclSerializer : public DeclVisitor<DeclSerializer> {
case DeclAttrKind::Execution: {
auto *theAttr = cast<ExecutionAttr>(DA);
auto abbrCode = S.DeclTypeAbbrCodes[ExecutionDeclAttrLayout::Code];
ExecutionDeclAttrLayout::emitRecord(S.Out, S.ScratchRecord, abbrCode,
(unsigned)theAttr->getKind());
ExecutionDeclAttrLayout::emitRecord(
S.Out, S.ScratchRecord, abbrCode,
static_cast<uint8_t>(theAttr->getBehavior()));
return;
}