diff options
| author | Daniel Gavin <danielgavin5@hotmail.com> | 2022-07-20 22:03:57 +0200 |
|---|---|---|
| committer | Daniel Gavin <danielgavin5@hotmail.com> | 2022-07-20 22:03:57 +0200 |
| commit | fa46573d263ae3202dd6820147968b4cfb43fa4b (patch) | |
| tree | af5061c4bdeffb8445f9871ed8e5a4696fa44c82 /tools | |
| parent | 9087a6e0ec7c2dfe2fe7b8bd9dfde8817afbd16d (diff) | |
Refractor nest procedure for odinfmt
Diffstat (limited to 'tools')
| -rw-r--r-- | tools/odinfmt/snapshot/snapshot.odin | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tools/odinfmt/snapshot/snapshot.odin b/tools/odinfmt/snapshot/snapshot.odin index 81d48ad..42f8034 100644 --- a/tools/odinfmt/snapshot/snapshot.odin +++ b/tools/odinfmt/snapshot/snapshot.odin @@ -63,7 +63,8 @@ snapshot_file :: proc(path: string) -> bool { fmt.eprintf("\nFormatted file was different from snapshot file: %v", snapshot_path) os.write_entire_file(fmt.tprintf("%v_failed", snapshot_path), transmute([]u8)formatted) return false - } + } + os.remove(fmt.tprintf("%v_failed", snapshot_path)) } else { fmt.eprintf("Failed to read snapshot file %v", snapshot_path) return false @@ -80,4 +81,4 @@ snapshot_file :: proc(path: string) -> bool { fmt.print(" - SUCCESS \n") return true -}
\ No newline at end of file +} |