Skip to content

Commit b937eb3

Browse files
grandizzyDaniPopeszerosnacks
authored
fix(fmt): 'layout' is not a keyword (backport to 1.2.2) (#10669)
* fix(fmt): 'layout' is not a keyword (#10656) * chore: bump version to 1.2.2 (#10668) * ci: use Optimism mainnet instead of DRPC due to limits (#10592) use Optimism mainnet instead of DRPC due to limits --------- Co-authored-by: DaniPopes <[email protected]> Co-authored-by: zerosnacks <[email protected]>
1 parent 42341d5 commit b937eb3

File tree

6 files changed

+53
-48
lines changed

6 files changed

+53
-48
lines changed

Cargo.lock

Lines changed: 32 additions & 32 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ members = [
2727
resolver = "2"
2828

2929
[workspace.package]
30-
version = "1.2.1"
30+
version = "1.2.2"
3131
edition = "2021"
3232
# Remember to update clippy.toml as well
3333
rust-version = "1.83"
@@ -191,7 +191,7 @@ foundry-linking = { path = "crates/linking" }
191191
foundry-block-explorers = { version = "0.13.3", default-features = false }
192192
foundry-compilers = { version = "0.14.0", default-features = false }
193193
foundry-fork-db = "0.12"
194-
solang-parser = { version = "=0.3.8", package = "foundry-solang-parser" }
194+
solang-parser = { version = "=0.3.9", package = "foundry-solang-parser" }
195195
solar-parse = { version = "=0.1.2", default-features = false }
196196
solar-sema = { version = "=0.1.2", default-features = false }
197197

crates/fmt/testdata/NonKeywords/fmt.sol

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
struct S {
22
uint256 error;
3-
// uint256 layout;
3+
uint256 layout;
44
uint256 at;
55
}
66
// uint256 transient;
77

88
function f() {
99
uint256 error = 0;
10-
// uint256 layout = 0;
10+
uint256 layout = 0;
1111
uint256 at = 0;
1212
// uint256 transient = 0;
1313

@@ -17,25 +17,26 @@ function f() {
1717
// transient = 0;
1818

1919
S memory x = S({
20+
// format
2021
error: 0,
21-
// layout: 0,
22+
layout: 0,
2223
at: 0
2324
});
2425
// transient: 0
2526

2627
x.error = 0;
27-
// x.layout = 0;
28+
x.layout = 0;
2829
x.at = 0;
2930
// x.transient = 0;
3031

3132
assembly {
3233
let error := 0
33-
// let layout := 0
34+
let layout := 0
3435
let at := 0
3536
// let transient := 0
3637

3738
error := 0
38-
// layout := 0
39+
layout := 0
3940
at := 0
4041
// transient := 0
4142
}

crates/fmt/testdata/NonKeywords/original.sol

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
struct S {
22
uint256 error;
3-
// uint256 layout;
3+
uint256 layout;
44
uint256 at;
55
// uint256 transient;
66
}
77

88
function f() {
99
uint256 error = 0;
10-
// uint256 layout = 0;
10+
uint256 layout = 0;
1111
uint256 at = 0;
1212
// uint256 transient = 0;
1313

@@ -17,25 +17,26 @@ function f() {
1717
// transient = 0;
1818

1919
S memory x = S({
20+
// format
2021
error: 0,
21-
// layout: 0,
22+
layout: 0,
2223
at: 0
2324
// transient: 0
2425
});
2526

2627
x.error = 0;
27-
// x.layout = 0;
28+
x.layout = 0;
2829
x.at = 0;
2930
// x.transient = 0;
3031

3132
assembly {
3233
let error := 0
33-
// let layout := 0
34+
let layout := 0
3435
let at := 0
3536
// let transient := 0
3637

3738
error := 0
38-
// layout := 0
39+
layout := 0
3940
at := 0
4041
// transient := 0
4142
}

0 commit comments

Comments
 (0)