nitc :: ModelBuilder :: cache_file
{filepath}.tmp
and replace the original if different
# Cache a file as `{filepath}.tmp` and replace the original if different
private fun cache_file(filepath: String): FileWriter do
if toolcontext.opt_ant.value and filepath.file_exists then
return new FileWriter.open("{filepath}.tmp")
else
return new FileWriter.open(filepath)
end
end
src/compiler/java_compiler.nit:102,2--109,4