nitc :: ModelBuilder :: close_cache
# Close the writer and move tmp file to original if modified
private fun close_cache(filepath: String, file: FileWriter) do
file.close
if "{filepath}.tmp".file_exists then
sys.system("if ! diff {filepath}.tmp {filepath} > /dev/null; then mv {filepath}.tmp {filepath}; else rm {filepath}.tmp; fi")
end
end
src/compiler/java_compiler.nit:111,2--117,4