From 19b95349a6f127efd1d858bfa0d6f3b4187801ce Mon Sep 17 00:00:00 2001 From: gingerBill Date: Sat, 24 Aug 2024 14:47:33 +0100 Subject: [PATCH] Use `fmt.caprintf` directly --- vendor/raylib/raylib.odin | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/vendor/raylib/raylib.odin b/vendor/raylib/raylib.odin index 835a1cf88..b2010c7a1 100644 --- a/vendor/raylib/raylib.odin +++ b/vendor/raylib/raylib.odin @@ -1684,8 +1684,7 @@ TextFormat :: proc(text: cstring, args: ..any) -> cstring { // Text formatting with variables (sprintf style) and allocates (must be freed with 'MemFree') TextFormatAlloc :: proc(text: cstring, args: ..any) -> cstring { - str := fmt.tprintf(string(text), ..args) - return strings.clone_to_cstring(str, MemAllocator()) + return fmt.caprintf(string(text), ..args, allocator=MemAllocator()) }