Skip to content

Enforce No Args Fallback Return Type#189

Open
rauljordan wants to merge 3 commits into
mainfrom
fallback-fix-dec-23-2
Open

Enforce No Args Fallback Return Type#189
rauljordan wants to merge 3 commits into
mainfrom
fallback-fix-dec-23-2

Conversation

@rauljordan

Copy link
Copy Markdown
Contributor

The fallback func with no args should return Result<(), Vec>. It should not be possible to return Result<Vec, Vec>. Having an explicit match statement fixes the issue

@gligneul

Copy link
Copy Markdown
Contributor

I think at some point would be better to manually verify the return type instead of relying on type inference of generated code. The error messages would probably be better as well.

@rauljordan

Copy link
Copy Markdown
Contributor Author

Agreed...I think I'll go ahead and do that before we merge

@rauljordan rauljordan changed the base branch from rel/0.7.0-rc.1 to main March 19, 2025 18:15
@rauljordan

Copy link
Copy Markdown
Contributor Author

Resolved with your feedback @gligneul

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants