Closed euclidianAce closed 2 years ago
Thanks!
I'm going to revert this because it's causing this problem to happen:
Can you spot the error? The diagnostic doesn't help because it's wrong
Reverted in 10ff26328cf8e5ed2938b96da6f8c20737eb444a. Now it's fixed:
This splits up the ast check and formatting actions on save so that formatting can still run when there are simple errors like unused variables, but the errors still show up after formatting. Additionally this allows disabling one or the other (or both) through
g:zig_fmt_autosave
,g:zig_ast_check_autosave
. To have the old behavior of runningzig fmt --ast-check
you can useg:zig_fmt_ast_check_autosave = 1