-
Notifications
You must be signed in to change notification settings - Fork 16
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
actor API syntax #75
base: master
Are you sure you want to change the base?
actor API syntax #75
Conversation
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.
I've looked at the syntax PR. In src/parse/app.rs
line 396, I don't quite follow
let ident = field.ident.as_ref().expect("UNREACHABLE");
Can this expect
be triggered, if so how, and what would the implication be (what happens if the identifier is set to "UNREACHABLE")?
As I understand the extension of the syntax allow init
to optionally return an actors struct, and current projects should still work as before.
Is there a mechanism checking if an Actor struct has been declared but not used returned by init?
/Per
Another thing that would be good is some more tests (if I'm not mistaken there is just one test assumed to pass, no fail tests). |
@perlindgren the
that panicking branch cannot be hit due to guarantees in the if you see a few lines above you'll see that the code is handling the Lines 394 to 396 in e19feea
the
yes, there's a parser check for that. if an Lines 574 to 582 in e19feea
indeed, there are "success path" tests but no "failure path" tests in this PR. it would be possible to test the failure condition about |
As discussed on the Matrix, the current consensus is a "forked release", under the same |
see rtic-rs/rfcs#52 for details includes: core proposal and first `#[init]` extension Co-authored-by: Jonas Schievink <jonasschievink@gmail.com>
see rtic-rs/rfcs#52 for details
includes: core proposal and first
#[init]
extensionCo-authored-by: Jonas Schievink jonasschievink@gmail.com