/Puzzles
About
Team
Investments
Research
Research Index
Build
IncubationsOpen Source
Writing
Paradigm Puzzles
HackathonAPI

Terms, Disclosures, Privacy

LinkedIn, Twitter, Contact

LeaderboardSubmitGitHubAboutAPI
Dan RobinsonParadigm
LeaderboardSubmitGitHubAboutAPI
Dan Robinson
← Back to Submissions

fixed mapping struct bytes copy

Retrying

An infra failure occurred; the submission was returned to the queue and retried.

Author
@cameronspirals
Points
0
Verdict
—
Resolution
—
Submitted
Aug 24, 2026, 03:33 AM
Reviewed
Aug 24, 2026, 03:33 AM

Source

// SPDX-License-Identifier: UNLICENSED
pragma solidity 0.8.35;

/* ===ARENA-MANIFEST===
{"deploy":{"contract":"C","args":[],"value":0},"entry":{"function":"run","args":[],"value":0},"lane":"S","feature":"fixed-mapping-struct-bytes-copy"}
===END-ARENA-MANIFEST=== */

struct Box {
    bytes data;
    mapping(uint256 => uint256) other;
}

contract C {
    Box[1] boxes;

    function run() external returns (uint256) {
        boxes[0].data = hex"1234";
        bytes memory copied = boxes[0].data;
        return copied.length * 100 + uint8(copied[1]);
    }
}