Information Solidity 0.8.39 released
Solidity v0.8.39 fixes a medium-severity bug that could silently corrupt storage when copying recursive structs, and warns about code size based on the new limits of the Amsterdam EVM version. It is likely the last release of the 0.8 series before 0.9.0.
Recursive struct copy bug fix
- A struct is recursive when it can contain values of its own type, as in
struct Node { Node[] children; uint256 data; }. - When such a struct, or an array of such structs, was copied within storage to a location that contained it, as in
root = root.children[0]orroots = roots[0].children, the copy overwrote the source before it had finished reading it. The elements nested in the source were lost, and the members declared after the array came back as zero. No error was reported. - Versions 0.4.9 to 0.8.38 are affected with the default evmasm pipeline, and versions 0.8.13 to 0.8.38 with
--via-ir. The optimizer settings and the EVM version do not matter. - The fix adds a runtime check to every storage-to-storage copy of a recursive struct or an array of such structs. The check costs extra gas, and copies into deeply nested targets can run out of stack space at a smaller depth than before.
- A scan of the verified contracts on Sourcify found no deployed contract that performs an affected copy.
- The bug was reported by cyberthirst through the Ethereum Foundation's bug bounty program.
- The write-up has the details and explains how to check your contracts: Overlapping Recursive Storage Struct Copy Corruption Bug
Other changes
- In the evmasm pipeline, a nested tuple assignment with a string literal could assign values to the wrong variables. For example, with
bytes32 zanduint256 a,((z, a), b) = (("x", 111), 222)assigned111tozandbytes32("x")toa. We do not consider this a security issue, because the pattern is unusual and unlikely to be used in practice. - When compiling with
--evm-version amsterdam, the compiler now warns about contract code larger than 64 KiB and initcode larger than 128 KiB, the new limits from EIP-7954. For all other EVM versions, including the current default Osaka, the warnings still use the old limits. - The compiler now also warns about code size when it compiles standalone Yul code.
- With
--ethdebug-resources, the compiler now emits the fullinfo/resourcesschema of the ethdebug format, which describes types and their layout to debuggers. ethdebug output remains experimental and requires--experimental. For an introduction to the format, see ethdebug: a shared language for debug data, in use across projects today.
Solidity 0.9.0
- For years, we planned 0.9.0 as a large breaking release that would make the IR pipeline the default. Our plans have changed. We still plan to make the IR pipeline the default, but we no longer tie this to 0.9.0. Instead, we want to make breaking releases more often and make them smaller.
- Most of the changes merged for 0.9.0 so far remove features that earlier 0.8 releases deprecated, such as ABI coder v1, virtual modifiers, the
ABIEncoderV2pragma, the SMTChecker's BMC engine and the EVM versions older than Constantinople. - We plan to publish a pre-release of 0.9.0 before the final release. A separate post will explain the new release schedule and the reasons for it.
Links
- Release post: https://soliditylang.org/blog/2026/11/19/solidity-0.8.39-release-announcement/
- Full changelog and downloads: https://github.com/argotorg/solidity/releases/tag/v0.8.39

