Skip to content

Commit 96357b6

Browse files
committed
add better f-string support for sim
1 parent 34b86cb commit 96357b6

File tree

4 files changed

+26
-30
lines changed

4 files changed

+26
-30
lines changed

Cargo.lock

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

Cargo.toml

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ authors = ["Diode Computers, Inc. <founders@diode.computer>"]
1111

1212
[workspace.dependencies]
1313
glam = "0.31.0"
14-
starlark = { git = "https://github.com/diodeinc/starlark-rust", rev = "e80bd650" }
15-
starlark_map = { git = "https://github.com/diodeinc/starlark-rust", rev = "e80bd650" }
16-
starlark_derive = { git = "https://github.com/diodeinc/starlark-rust", rev = "e80bd650" }
17-
starlark_syntax = { git = "https://github.com/diodeinc/starlark-rust", rev = "e80bd650" }
18-
allocative = { git = "https://github.com/diodeinc/starlark-rust", rev = "e80bd650" }
14+
starlark = { git = "https://github.com/diodeinc/starlark-rust", rev = "bd12784d" }
15+
starlark_map = { git = "https://github.com/diodeinc/starlark-rust", rev = "bd12784d" }
16+
starlark_derive = { git = "https://github.com/diodeinc/starlark-rust", rev = "bd12784d" }
17+
starlark_syntax = { git = "https://github.com/diodeinc/starlark-rust", rev = "bd12784d" }
18+
allocative = { git = "https://github.com/diodeinc/starlark-rust", rev = "bd12784d" }
1919

2020
ruff_python_formatter = { git = "https://github.com/astral-sh/ruff", tag = "0.13.0" }
2121
ruff_formatter = { git = "https://github.com/astral-sh/ruff", tag = "0.13.0" }

crates/pcb-zen-core/src/lang/net.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -163,11 +163,7 @@ where
163163

164164
impl<'v, V: ValueLike<'v>> std::fmt::Display for NetValueGen<V> {
165165
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
166-
write!(
167-
f,
168-
"{}(name: {:?}, id: {:?})",
169-
self.type_name, self.name, self.net_id
170-
)
166+
write!(f, "{}", self.name)
171167
}
172168
}
173169

crates/pcb-zen/tests/snapshots/input__module_io_rejects_interface_when_net_expected.snap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,12 +16,12 @@ expression: snapshot_output
1616
)
1717
)
1818
)
19-
Error: Input 'signal' (type) has wrong type for this placeholder: expected Net, got SingleNet(signal=Net(name: "SIG_signal", id: <ID>))
19+
Error: Input 'signal' (type) has wrong type for this placeholder: expected Net, got SingleNet(signal=SIG_signal)
2020
╭─[ [TEMP_DIR]child.zen:2:10 ]
2121
2222
2signal = io("signal", Net)
2323
│ ────────┬────────
24-
│ ╰────────── Input 'signal' (type) has wrong type for this placeholder: expected Net, got SingleNet(signal=Net(name: "SIG_signal", id: <ID>))
24+
│ ╰────────── Input 'signal' (type) has wrong type for this placeholder: expected Net, got SingleNet(signal=SIG_signal)
2525
2626
├─[ [TEMP_DIR]parent.zen:8:1 ]
2727

0 commit comments

Comments
 (0)