Skip to content

Commit 46eb694

Browse files
committed
Merge branch 'main' into klkvr/settings-profiles
2 parents 5b42d05 + 21617d0 commit 46eb694

File tree

33 files changed

+624
-377
lines changed

33 files changed

+624
-377
lines changed

CHANGELOG.md

Lines changed: 43 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -5,54 +5,82 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8-
## [0.11.0](https://github.com/foundry-rs/compilers/releases/tag/v0.11.0) - 2024-09-02
8+
## [0.11.6](https://github.com/foundry-rs/compilers/releases/tag/v0.11.6) - 2024-10-16
99

10-
### Dependencies
10+
### Bug Fixes
1111

12-
- [deps] Bump alloy ([#193](https://github.com/foundry-rs/compilers/issues/193))
12+
- Correctly handle b as pre-release in Vyper version ([#213](https://github.com/foundry-rs/compilers/issues/213))
13+
- Accept partial first sourcemap element ([#209](https://github.com/foundry-rs/compilers/issues/209))
1314

14-
## [0.10.3](https://github.com/foundry-rs/compilers/releases/tag/v0.10.3) - 2024-08-26
15+
### Miscellaneous Tasks
16+
17+
- Release 0.11.5
18+
- Allow adding vyper sources with `add_raw_source` w/ `.vy` / `.vyi` extension ([#211](https://github.com/foundry-rs/compilers/issues/211))
19+
- [`ci`] Fix deny (add `ZLib` exception) ([#212](https://github.com/foundry-rs/compilers/issues/212))
20+
21+
## [0.11.4](https://github.com/foundry-rs/compilers/releases/tag/v0.11.4) - 2024-10-02
1522

1623
### Bug Fixes
1724

18-
- [flatten] Update license handling logic ([#184](https://github.com/foundry-rs/compilers/issues/184))
25+
- Include `evm.legacyAssembly` output ([#206](https://github.com/foundry-rs/compilers/issues/206))
26+
- Ast Node Bindings ([#199](https://github.com/foundry-rs/compilers/issues/199))
27+
- Actualize output selection options ([#196](https://github.com/foundry-rs/compilers/issues/196))
28+
29+
### Dependencies
30+
31+
- [deps] Bump alloy ([#193](https://github.com/foundry-rs/compilers/issues/193))
1932

2033
### Documentation
2134

22-
- Docs fix spelling issues ([#190](https://github.com/foundry-rs/compilers/issues/190))
35+
- Fix typos ([#202](https://github.com/foundry-rs/compilers/issues/202))
2336

2437
### Features
2538

26-
- Always provide `Default` for `MultiCompiler` ([#188](https://github.com/foundry-rs/compilers/issues/188))
27-
- [vyper] Add experimental codegen to settings ([#186](https://github.com/foundry-rs/compilers/issues/186))
28-
- More user-friendly error when no compiler is available ([#185](https://github.com/foundry-rs/compilers/issues/185))
39+
- Better extra_args handling ([#208](https://github.com/foundry-rs/compilers/issues/208))
40+
- Better error messages for incompatible versions ([#200](https://github.com/foundry-rs/compilers/issues/200))
2941

3042
### Miscellaneous Tasks
3143

32-
- Release 0.10.3
33-
34-
### Other
35-
36-
- Incorrect Default EVM Version for Solidity Compiler 0.4.21-0.5.4 ([#189](https://github.com/foundry-rs/compilers/issues/189))
44+
- Release 0.11.4
45+
- Release 0.11.3
46+
- Proper generate legacy asm extra output file ([#207](https://github.com/foundry-rs/compilers/issues/207))
47+
- Release 0.11.2
48+
- Clippy ([#204](https://github.com/foundry-rs/compilers/issues/204))
49+
- Use serde_json::from_str ([#203](https://github.com/foundry-rs/compilers/issues/203))
50+
- Release 0.11.1
51+
- Improve error handling in source map parsing ([#201](https://github.com/foundry-rs/compilers/issues/201))
52+
- Clippy happy ([#195](https://github.com/foundry-rs/compilers/issues/195))
53+
- Fix up the README example ([#194](https://github.com/foundry-rs/compilers/issues/194))
54+
- Release 0.11.0
3755

38-
## [0.10.2](https://github.com/foundry-rs/compilers/releases/tag/v0.10.2) - 2024-08-01
56+
## [0.10.3](https://github.com/foundry-rs/compilers/releases/tag/v0.10.3) - 2024-08-26
3957

4058
### Bug Fixes
4159

60+
- [flatten] Update license handling logic ([#184](https://github.com/foundry-rs/compilers/issues/184))
4261
- Unify logic for ignored warnings ([#179](https://github.com/foundry-rs/compilers/issues/179))
4362
- Remove outdated build infos ([#177](https://github.com/foundry-rs/compilers/issues/177))
4463
- Make remappings resolution more deterministic ([#176](https://github.com/foundry-rs/compilers/issues/176))
4564

65+
### Documentation
66+
67+
- Docs fix spelling issues ([#190](https://github.com/foundry-rs/compilers/issues/190))
68+
4669
### Features
4770

71+
- Always provide `Default` for `MultiCompiler` ([#188](https://github.com/foundry-rs/compilers/issues/188))
72+
- [vyper] Add experimental codegen to settings ([#186](https://github.com/foundry-rs/compilers/issues/186))
73+
- More user-friendly error when no compiler is available ([#185](https://github.com/foundry-rs/compilers/issues/185))
4874
- Sanitize EVM version for vyper ([#181](https://github.com/foundry-rs/compilers/issues/181))
4975

5076
### Miscellaneous Tasks
5177

78+
- Release 0.10.3
5279
- Release 0.10.2
5380

5481
### Other
5582

83+
- Incorrect Default EVM Version for Solidity Compiler 0.4.21-0.5.4 ([#189](https://github.com/foundry-rs/compilers/issues/189))
5684
- Update README to link docs and update install instructions ([#180](https://github.com/foundry-rs/compilers/issues/180))
5785

5886
## [0.10.1](https://github.com/foundry-rs/compilers/releases/tag/v0.10.1) - 2024-07-26

Cargo.toml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ resolver = "2"
44

55
[workspace.package]
66
authors = ["Foundry Maintainers"]
7-
version = "0.11.0"
7+
version = "0.11.6"
88
rust-version = "1.70"
99
readme = "README.md"
1010
license = "MIT OR Apache-2.0"
@@ -31,11 +31,11 @@ unused-must-use = "deny"
3131
all = "warn"
3232

3333
[workspace.dependencies]
34-
foundry-compilers = { path = "crates/compilers", version = "0.11.0" }
35-
foundry-compilers-artifacts = { path = "crates/artifacts/artifacts", version = "0.11.0" }
36-
foundry-compilers-artifacts-solc = { path = "crates/artifacts/solc", version = "0.11.0" }
37-
foundry-compilers-artifacts-vyper = { path = "crates/artifacts/vyper", version = "0.11.0" }
38-
foundry-compilers-core = { path = "crates/core", version = "0.11.0" }
34+
foundry-compilers = { path = "crates/compilers", version = "0.11.6" }
35+
foundry-compilers-artifacts = { path = "crates/artifacts/artifacts", version = "0.11.6" }
36+
foundry-compilers-artifacts-solc = { path = "crates/artifacts/solc", version = "0.11.6" }
37+
foundry-compilers-artifacts-vyper = { path = "crates/artifacts/vyper", version = "0.11.6" }
38+
foundry-compilers-core = { path = "crates/core", version = "0.11.6" }
3939

4040
alloy-json-abi = { version = "0.8", features = ["serde_json"] }
4141
alloy-primitives = { version = "0.8", features = ["serde", "rand"] }
@@ -62,3 +62,5 @@ yansi = "1.0"
6262
# async
6363
futures-util = "0.3"
6464
tokio = { version = "1.35", features = ["rt-multi-thread"] }
65+
66+
snapbox = "0.6.9"

crates/artifacts/solc/src/ast/mod.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -257,7 +257,7 @@ pub enum AssignmentOperator {
257257
ShlAssign,
258258
}
259259

260-
ast_node!(
260+
expr_node!(
261261
/// A binary operation.
262262
struct BinaryOperation {
263263
common_type: TypeDescriptions,
@@ -938,7 +938,7 @@ stmt_node!(
938938
/// A return statement.
939939
struct Return {
940940
expression: Option<Expression>,
941-
function_return_parameters: usize,
941+
function_return_parameters: Option<usize>,
942942
}
943943
);
944944

crates/artifacts/solc/src/configurable.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,8 @@ pub struct ConfigurableContractArtifact {
2323
#[serde(default, skip_serializing_if = "Option::is_none")]
2424
pub assembly: Option<String>,
2525
#[serde(default, skip_serializing_if = "Option::is_none")]
26+
pub legacy_assembly: Option<serde_json::Value>,
27+
#[serde(default, skip_serializing_if = "Option::is_none")]
2628
pub opcodes: Option<String>,
2729
#[serde(default, skip_serializing_if = "Option::is_none")]
2830
pub method_identifiers: Option<BTreeMap<String, String>>,

crates/artifacts/solc/src/contract.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -455,7 +455,7 @@ pub struct CompactContractRefSome<'a> {
455455
pub bin_runtime: &'a BytecodeObject,
456456
}
457457

458-
impl<'a> CompactContractRefSome<'a> {
458+
impl CompactContractRefSome<'_> {
459459
/// Returns the individual parts of this contract.
460460
///
461461
/// If the values are `None`, then `Default` is returned.

crates/artifacts/solc/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1150,7 +1150,7 @@ impl<'de> Deserialize<'de> for LosslessMetadata {
11501150
{
11511151
struct LosslessMetadataVisitor;
11521152

1153-
impl<'de> Visitor<'de> for LosslessMetadataVisitor {
1153+
impl Visitor<'_> for LosslessMetadataVisitor {
11541154
type Value = LosslessMetadata;
11551155

11561156
fn expecting(&self, formatter: &mut fmt::Formatter<'_>) -> fmt::Result {

crates/artifacts/solc/src/output_selection.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,8 @@ use std::{collections::BTreeMap, fmt, str::FromStr};
66
/// Represents the desired outputs based on a File `(file -> (contract -> [outputs]))`
77
pub type FileOutputSelection = BTreeMap<String, Vec<String>>;
88

9-
/// Represents the selected output of files and contracts
9+
/// Represents the selected output of files and contracts.
10+
///
1011
/// The first level key is the file name and the second level key is the
1112
/// contract name. An empty contract name is used for outputs that are
1213
/// not tied to a contract but to the whole source file like the AST.
@@ -378,7 +379,7 @@ impl FromStr for EvmOutputSelection {
378379
match s {
379380
"evm" => Ok(Self::All),
380381
"asm" | "evm.assembly" => Ok(Self::Assembly),
381-
"evm.legacyAssembly" => Ok(Self::LegacyAssembly),
382+
"legacyAssembly" | "evm.legacyAssembly" => Ok(Self::LegacyAssembly),
382383
"methodidentifiers" | "evm.methodIdentifiers" | "evm.methodidentifiers" => {
383384
Ok(Self::MethodIdentifiers)
384385
}

crates/artifacts/solc/src/remappings.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -723,7 +723,7 @@ fn find_remapping_candidates(
723723

724724
// need to find the actual next window in the event `open` is a lib dir
725725
let window_start = next_nested_window(open, current_dir);
726-
// finally, we need to merge, adjust candidates from the same level and opening window
726+
// finally, we need to merge, adjust candidates from the same level and open window
727727
if is_candidate
728728
|| candidates
729729
.iter()
@@ -771,8 +771,8 @@ fn dir_distance(root: &Path, current: &Path) -> usize {
771771
}
772772

773773
/// This finds the next window between `root` and `current`
774-
/// If `root` ends with a `lib` component then start join components from `current` until no valid
775-
/// window opener is found
774+
/// If `root` ends with a `lib` component then start joining components from `current` until no
775+
/// valid window opener is found
776776
fn next_nested_window(root: &Path, current: &Path) -> PathBuf {
777777
if !is_lib_dir(root) || root == current {
778778
return root.to_path_buf();

0 commit comments

Comments
 (0)