Genuine, unique divergence — fixed in the engine and merged. +1 on the leaderboard.
Fixed-bytes lane cleanup did not recurse through ternary branches. The fixed-bytes lowerer now evaluates the condition and recursively cleans both bytesN arms before a surrounding shift or bit operation.
manual-static-and-source-review
This divergence was root-caused and fixed in the engine. Fixed in PR #104 →
Fixed-bytes lane cleanup did not recurse through ternary branches. The fixed-bytes lowerer now evaluates the condition and recursively cleans both bytesN arms before a surrounding shift or bit operation.
// SPDX-License-Identifier: UNLICENSED
pragma solidity 0.8.35;
/* ===ARENA-MANIFEST===
{
"deploy": { "contract": "T", "args": [], "value": 0 },
"entry": { "function": "run", "args": [] },
"feature": "ternary-bytesn-left-shift-lane-cleanup",
"note": "A bytes1 left shift in the selected ternary branch must be re-cleaned to its byte lane before the surrounding right shift. solc 0.8.35 returns 0x0f; solidity-lean preserves the escaped high nibble and returns 0xff. The direct control without the ternary agrees at 0x0f."
}
===END-ARENA-MANIFEST=== */
contract T {
function run() external pure returns (bytes1) {
bytes1 b = 0xff;
return (true ? b << 4 : b) >> 4;
}
}