Documentation

ReadCompleteFile

ReadCompleteFile Description Read complete contents of file at once. Pointer returned is malloc’d and hence must be freed after use. The returned pointer can also be reused by providing pointer to it in data parameter. realloc is called on *data in order to expand it’s size. If *capacity exceeds the size of file to be loaded, then no reallocation is performed. This means the provided buffer will automatically be expanded if required. The returned buffer is null-terminated just-in-case. The implementation and API is designed in such a way that it can be used with containers like Vec and Str.

Read More

ReadFmt

ReadFmt Description Read formatted input from the standard input stream (stdin). This is a convenience macro calling FReadFmt with stdin.

Read More

run_test_suite

run_test_suite Description Main test driver that handles both normal and deadend tests.

Read More

Scope

Scope Description Run a scoped block and automatically deinitialize the object at the end. Executes scope_body and ensures obj_deinit(obj) is called afterward, regardless of the block’s control flow. This is similar to RAII-style resource management in C++ but implemented manually via a macro. The object is passed by pointer. It is not copied or moved. This macro ensures the object is only evaluated once by capturing it internally using TYPE_OF. The memory pointed to by obj is not cleared after deinitialization; if zeroing is needed, do it inside obj_deinit. Parameters:

Read More

simple_test_driver

simple_test_driver Description Run an array of simple test functions.

Read More

StrBegin

StrBegin Description Get pointer to first character in string

Read More

StrCharAt

StrCharAt Description Access character at given index

Read More

StrCharPtrAt

StrCharPtrAt Description Get pointer to character at given index

Read More

StrClear

StrClear Description Set string length to 0.

Read More

StrCmp

StrCmp Description Compare two Str objects

Read More