fix: Print comptime::Value better#5655
fix: Print comptime::Value better#5655jfecher merged 4 commits intojf/quoted-to-trait-constraintsfrom
comptime::Value better#5655Conversation
Changes to circuit sizes
🧾 Summary (10% most significant diffs)
Full diff report 👇
|
asterite
left a comment
There was a problem hiding this comment.
LGTM
Is there a way to test this? (maybe it's tricky because this would be the output of a println call?)
|
@asterite not that I know of besides testing it manually. I'm surprised there are circuit size changes here at all though. Especially considering this is just changing the comptime values printing and not runtime ones. |
|
Ah, you are right. I just checked out the branch this PR is on top of, |
|
Nevermind, now I don't get that difference in that other PR... 🤔 |
|
Oh, and merging this branch against master makes it go down again... I think. We'll have to wait for the other PR to get merged, then merge against master. |
Yeah I think so as well. If you look in the |
# Description ## Problem\* Resolves <!-- Link to GitHub Issue --> ## Summary\* We stored `comptime_scopes` in the Elaborator, but elaborators are created one per each crate. So any globals from other crates would be invisible to each next crate, or their value would be reset. I've moved `comptime_scopes` to the NodeInterner to fix this. ## Additional Context With this, `derive` now works in the stdlib. I've decided to split adding that into a separate PR though. ## Documentation\* Check one: - [x] No documentation needed. - [ ] Documentation included in this PR. - [ ] **[For Experimental Features]** Documentation to be submitted in a separate PR. # PR Checklist\* - [x] I have tested the changes locally. - [x] I have formatted the changes with [Prettier](https://prettier.io/) and/or `cargo fmt` on default settings.
Description
Problem*
Summary*
Several Value variants are just ids which we previously couldn't print well. I've added a helper type to hold a NodeInterner so that we can print the names of these values as well. This will now print, e.g.
Eqinstead of(trait definition)Additional Context
Documentation*
Check one:
PR Checklist*
cargo fmton default settings.