MCPcopy Create free account
hub / github.com/WheretIB/nullc / FileWrite

Function FileWrite

NULLC/includes/file.cpp:140–149  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

138 nullcThrowError("Failed to read from a file.");
139 }
140 void FileWrite(NULLCArray arr, File* file)
141 {
142 if(!file->handle)
143 {
144 nullcThrowError("Cannot write to a closed file.");
145 return;
146 }
147 if(arr.len != fwrite(arr.ptr, 1, arr.len, file->handle))
148 nullcThrowError("Failed to write to a file.");
149 }
150 void FilePrint(NULLCArray arr, File* file)
151 {
152 if(!file->handle)

Callers

nothing calls this directly

Calls 1

nullcThrowErrorFunction · 0.50

Tested by

no test coverage detected