Skip to content
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

astgen: fix error return trace on error union switch #18599

Merged
merged 2 commits into from
Jan 19, 2024

Conversation

dweiller
Copy link
Contributor

@dweiller dweiller commented Jan 17, 2024

Fixes #18591 and #18574.

@dweiller
Copy link
Contributor Author

Is there a way to add tests for error return traces?

@dweiller dweiller force-pushed the err-union-switch-err-trace branch from 8ad238f to b6fa9af Compare January 17, 2024 16:57
@dweiller dweiller force-pushed the err-union-switch-err-trace branch from b6fa9af to 7ef3d38 Compare January 17, 2024 17:47
@Vexu
Copy link
Member

Vexu commented Jan 17, 2024

Yes, see the PR that added save_err_ret_index behavior for examples: #12837 (test/stack_traces.zig file)

@dweiller dweiller force-pushed the err-union-switch-err-trace branch from 3cc761e to c4cff44 Compare January 18, 2024 04:12
@andrewrk andrewrk merged commit 6ecf3b1 into ziglang:master Jan 19, 2024
10 checks passed
@andrewrk
Copy link
Member

Thanks!

@dweiller dweiller deleted the err-union-switch-err-trace branch February 12, 2024 23:34
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.

switch on error preserves error return trace
3 participants