-
Notifications
You must be signed in to change notification settings - Fork 489
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
[Merged by Bors] - fix: use explicit Result
type from std on generated code
#3393
[Merged by Bors] - fix: use explicit Result
type from std on generated code
#3393
Conversation
f3e2985
to
a411806
Compare
First commit fails with test ui-tests/pass_derive_decode_encode_with_custom_results.rs ... error
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
error[E0107]: type alias takes 0 generic arguments but 2 generic arguments were supplied
--> ui-tests/pass_derive_decode_encode_with_custom_results.rs:7:19
|
7 | #[derive(Default, Decoder, Encoder)]
| ^^^^^^^- help: remove these generics
| |
| expected 0 generic arguments
|
note: type alias defined here, with 0 generic parameters
--> ui-tests/pass_derive_decode_encode_with_custom_results.rs:3:10
|
3 | pub type Result = std::result::Result<(), ()>;
| ^^^^^^
= note: this error originates in the derive macro `Decoder` (in Nightly builds, run with -Z macro-backtrace for more info)
error[E0107]: type alias takes 0 generic arguments but 2 generic arguments were supplied
--> ui-tests/pass_derive_decode_encode_with_custom_results.rs:7:28
|
7 | #[derive(Default, Decoder, Encoder)]
| ^^^^^^^- help: remove these generics
| |
| expected 0 generic arguments
|
note: type alias defined here, with 0 generic parameters
--> ui-tests/pass_derive_decode_encode_with_custom_results.rs:3:10
|
3 | pub type Result = std::result::Result<(), ()>;
| ^^^^^^
= note: this error originates in the derive macro `Encoder` (in Nightly builds, run with -Z macro-backtrace for more info)
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈ |
Result
type from std on generated code in order t…Result
type from std on generated code
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.
LGTM
bors r+ |
this is done in order to avoid issues that could happen if a different Result type is on scope
Build failed: |
bors r+ |
this is done in order to avoid issues that could happen if a different Result type is on scope
Build failed: |
ohh clippy issues from new version |
bors retry |
this is done in order to avoid issues that could happen if a different Result type is on scope
Pull request successfully merged into master. Build succeeded! The publicly hosted instance of bors-ng is deprecated and will go away soon. If you want to self-host your own instance, instructions are here. If you want to switch to GitHub's built-in merge queue, visit their help page. |
Result
type from std on generated codeResult
type from std on generated code
this is done in order to avoid issues that could happen if a different Result type is on scope