Qu

create_file

Builtin index · File I/O

create_file(path, [on_exists="error"])

Input: path, on_exists · Output: no output

What it is

make_file with a collision policy: "error" (default) refuses if path already exists, "overwrite" truncates it like make_file does unconditionally, "skip" does nothing and returns false. make_file itself is unchanged — this is the builtin for callers who need to say what should happen on collision, not a replacement for it.

Overloads

One call shape — this function is not overloaded.

CodeInputOutputDescription
create_file(path, [on_exists="error"])
path —make_file with a collision policy: "error" (default) refuses if path already exists, "overwrite" truncates it like make_file does unconditionally, "skip" does nothing and returns false.
on_exists optional (default "error")not documented yet
not documented yetmake_file itself is unchanged — this is the builtin for callers who need to say what should happen on collision, not a replacement for it.

Examples

No documentation example calls this form yet. The File I/O chapter is where one belongs.