#define EV_STR_IMPLEMENTATION #include "ev_str.h" #include #include static evstring global_str = evstr("Global 'Hello, World!'"); int main(void) { const evstring stack_str = evstr("Stack 'Hello, World!'"); assert(strcmp(stack_str, "Stack 'Hello, World!'") == 0); assert(evstring_getLength(stack_str) == 21); assert(strcmp(global_str, "Global 'Hello, World!'") == 0); assert(evstring_getLength(global_str) == 22); evstring heap_str = evstring_new("Heap 'Hello, World!'"); assert(heap_str != NULL); assert(strcmp(heap_str, "Heap 'Hello, World!'") == 0); assert(evstring_getLength(heap_str) == 20); evstring_free(heap_str); return 0; }