-
Notifications
You must be signed in to change notification settings - Fork 15
Get underling values of Fields #49
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
@HKalbasi it seems Rust 1.91 has started printing thread IDs on panics, which is breaking our diff-based example testing. Any suggestions on how to proceed? I don't see an obvious way to turn off that panic behavior. |
|
Seems we may need #50 before merging this. |
Ah, this is rust-lang/rust#115746 . Let's use the stable compiler instead of nightly for now, and hope that they will make an option to disable this behavior before this hits stable. I like to avoid regex if possible, since it will break the ability of auto-fixing the tests. |
|
@HKalbasi I'm trying to figure out why |
|
IIRC examples enable lto with clang and use lld. Might be related. |
|
Well, I'm not sure why this PR broke it, but setting |
| These wrappers now act as their underlying type `T` in many contexts: | ||
|
|
||
| - `Ref<T>` construction from any `Field*<T, OFFSET>` | ||
| - Implicit read via `operator T()` and `.read()` for value-like access |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This .read() is leftover.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, good catch! Thanks.
Currently, it does not seem possible to read the underling value of zngur fields in C++. This PR adds support for converting a
Field<T>to aT, and adds corresponding docs and tests.