Skip to content

Commit 21f4064

Browse files
committed
[Runtime] Fix singlePayloadEnumSimpleAssignWithCopy
1 parent 0ff7f1d commit 21f4064

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

stdlib/public/runtime/BytecodeLayouts.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1404,13 +1404,13 @@ static void singlePayloadEnumSimpleAssignWithCopy(const Metadata *metadata,
14041404

14051405
if (srcTagBytes >= xiTagValues && destTagBytes >= xiTagValues) {
14061406
return;
1407-
} else if (destTagBytes >= xiTagValues) {
1407+
} else if (srcTagBytes >= xiTagValues) {
14081408
const uint8_t *end = (reader.layoutStr + refCountBytes);
14091409
while (reader.layoutStr < end) {
14101410
handleSingleRefCountInitWithCopy(metadata, reader, addrOffset, dest, src);
14111411
}
14121412
return;
1413-
} else if (srcTagBytes >= xiTagValues) {
1413+
} else if (destTagBytes >= xiTagValues) {
14141414
const uint8_t *end = (reader.layoutStr + refCountBytes);
14151415
while (reader.layoutStr < end) {
14161416
handleSingleRefCountDestroy(metadata, reader, addrOffset, dest);

0 commit comments

Comments
 (0)