Write to an in-memory buffer before writing to an actual output file
We don't want to leave a partial assembly output if the compiler fails during compilation. Technically speaking, there's still a risk of leaving a partially- written output file if the compiler dies during file copy. To fix that, we have to write to a temporary file in the same filesystem as the final output file and rename the temporary file to atomically replace the output file. We don't do that in this patch for the sake of succinctness, though.
parent
f0cb3a3c
Please register or sign in to comment