Skip to content

upstream merge through commit 0a1c495 (0.19.1)#12

Merged
cdrappi merged 58 commits intoseismicfrom
usm
Sep 30, 2025
Merged

upstream merge through commit 0a1c495 (0.19.1)#12
cdrappi merged 58 commits intoseismicfrom
usm

Conversation

@cdrappi
Copy link
Contributor

@cdrappi cdrappi commented Sep 12, 2025

No description provided.

wtdcode and others added 30 commits May 21, 2025 11:07
Trivial patch. The new variant `transient` seems missing.
Replaced the outdated or broken link to the Tera template engine
documentation in cliff.toml with the current one:
https://keats.github.io/tera/docs/#introduction

This change helps users quickly find up-to-date documentation for the
template syntax used in the changelog configuration.
Trivial patch.

Reproduce:

```bash
echo '{"language":"Solidity","sources":{"test.sol":{"content":"contract TT {\\n    function main() public {}\\n}"}},"settings":{"stopAfter":"parsing","optimizer":{"enabled":false,"runs":200},"outputSelection":{"*":{"":["ast"],"*":[]}},"viaIR":true,"libraries":{}}}' | solc --standard-json
```

Since there is no semantics analysis when stopping after parsing,
`scope` along with a few other fields are not available and this PR
marks all `scope` to be optional.
I got a `ERROR` log when using `forge flatten` with no extra message,
and the error itself gets ignored with a fallback

---------

Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de>
…th `CI` and `Cargo.toml` (#277)

Closes: #266
EOF has been deprecated in Foundry

Remove unused `serde_repr` dependency
This PR adds a few missing NodeTypes for the node AST.
## Problem

The `NodeType` enum had an `Other(String)` variant intended to catch unknown
AST node types, but it wasn't working correctly. The issue was that serde's
default enum serialization uses tagged format (e.g., `{"Other": "UnknownType"}`),
but Solidity AST serializes node types as simple strings (e.g., `"UnknownType"`).

When encountering an unknown node type like `"SomeNewNodeType"`, the deserializer
would fail instead of falling back to the `Other` variant.

## Solution

Implemented custom `Serialize` and `Deserialize` traits for `NodeType`:

- **Custom serialization**: All variants serialize as simple strings
- **Custom deserialization**: Known strings map to specific variants, unknown
  strings map to `Other(String)`
- **Backwards compatibility**: All existing functionality remains unchanged

## Testing

Added comprehensive tests covering:
- Unknown node type deserialization → `Other` variant
- Known node type deserialization (unchanged behavior)
- Roundtrip serialization for all node types
- Complete AST parsing with unknown node types
- Mixed known/unknown node structures

This ensures the library can handle future Solidity compiler versions that
introduce new AST node types without breaking existing code.

Closes #280

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
…… (#284)

…es (#280)"

This reverts commit 9920c74.

This was accidentally committed to main, 

supersedes #283
…(#286)

- Fixed typos in comments:
  - "identfiers" → "identifiers" in `output_selection.rs`
  - "blocking_intsall" → "blocking_install" in `compiler.rs`
  - "depeending" → "depending" in `compiler.rs`
- Corrected a variable name typo:
- "output_selecttion_specific" → "output_selection_specific` in
`output_selection.rs` tests
Adds support for Vyper 0.4.3 which now defaults to `prague`
bumps solar to v0.1.5 and MSRV to 1.88
Bump outdated dependencies as preparation for next release
zerosnacks and others added 28 commits July 14, 2025 11:09
This commit removes a redundant check for assembly in the is_dirty
method, leaving only a single, correct check for assembly. No other
logic was changed.
`#[instrument]` and clean up. No functional changes intended.
ref foundry-rs/foundry#6706
tested and confirm solves
foundry-rs/foundry#8499 too
- do not add trailing `/` to remappings if single .sol file remapped -
foundry-rs/foundry#6706 (comment)
- if `stripped_import` is empty then do not join when resolving library
import as will append `/` -
foundry-rs/foundry#6706 (comment)
- fix display so `forge remappings` properly display remappings
`@ens/utils/BytesUtils.sol=src/BytesUtils.sol`
Apply cargo update / upgrade + clippy / breaking change fixes
I don't really know why these re-implement svm functions

Closes foundry-rs/compilers#296
ref foundry-rs/foundry#11417
for
```Solidity
// SPDX-License-Identifier: MIT
pragma solidity >=0.8.19;
...

function convert(UD60x18 x) pure returns (uint256 result) {
...
}

function convert(uint256 x) pure returns (UD60x18 result) {
...
}
```

we have items as

```
[
  (8378, ItemLocation { path: "lib/prb-math/src/ud60x18/Conversions.sol", start: 462, end: 469 }), 
  (8409, ItemLocation { path: "lib/prb-math/src/ud60x18/Conversions.sol", start: 833, end: 840 })
]
```

but we sort only by path, hence order could be reversed.

Sort also by loc.start to make sure order is preserved
pushing to main directly is disabled
Allows persisting a shared
[`solar_sema::Compiler`](paradigmxyz/solar#397)
throughout compilation and storing it inside of the output.

---------

Co-authored-by: onbjerg <onbjerg@users.noreply.github.com>
FnOnce + Copy doesn't really make sense.
Making more readable and improving tracing. No functional changes.
Cache entries are keyed by absolute path relative to project root, but
it's possible to construct and pass in Sources from a relative path,
such as CLI argument in `forge lint`/`forge eip712`...

In these cases the path will be relative and will always be a cache
miss. This includes the path's imports, which get resolved as relative
to the initial path rather than root now with Solar.

Make all paths in Sources absolute when constructing Graph so that this
change propagates through the entire compilation process.

I couldn't find a reproducer in today's stable/nightly Foundry, however
making `config.solar_project()` use `project()` instead of
`ephemeral_project()` will reproduce the behavior explained above.

With this change, `solar_project` will almost never call to solc.
@cdrappi cdrappi merged commit 5477a89 into seismic Sep 30, 2025
4 checks passed
@cdrappi cdrappi deleted the usm branch September 30, 2025 17:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.