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

zig fmt segfaults on malformed variable #8974

Closed
Leguu opened this issue Jun 3, 2021 · 0 comments · Fixed by #8984
Closed

zig fmt segfaults on malformed variable #8974

Leguu opened this issue Jun 3, 2021 · 0 comments · Fixed by #8984
Labels
bug Observed behavior contradicts documented or intended behavior frontend Tokenization, parsing, AstGen, Sema, and Liveness.
Milestone

Comments

@Leguu
Copy link

Leguu commented Jun 3, 2021

Running zig fmt on a file that contains this:

pub const VARIABLE;

Causes it to create a segfault. This was annoying when using zig fmt . because the segfault caused the formatter to not format any files, and give no errors. It used to work in 0.7.1, but it doesn't work in the master branch.

@Vexu Vexu added bug Observed behavior contradicts documented or intended behavior frontend Tokenization, parsing, AstGen, Sema, and Liveness. labels Jun 3, 2021
@Vexu Vexu added this to the 0.8.0 milestone Jun 3, 2021
g-w1 added a commit to g-w1/zig that referenced this issue Jun 4, 2021
@g-w1 g-w1 mentioned this issue Jun 4, 2021
g-w1 added a commit to g-w1/zig that referenced this issue Jun 4, 2021
also add a regression test
g-w1 added a commit to g-w1/zig that referenced this issue Jun 4, 2021
also add a regression test
g-w1 added a commit to g-w1/zig that referenced this issue Jun 4, 2021
also add a regression test
@Vexu Vexu closed this as completed in #8984 Jun 4, 2021
Vexu pushed a commit that referenced this issue Jun 4, 2021
also add a regression test
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Observed behavior contradicts documented or intended behavior frontend Tokenization, parsing, AstGen, Sema, and Liveness.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants