News for hackers. Stuff that matters.

rallyroger

Re:Four Months of Zig on Wednesday October 28, 2026 @10:23AM (#50274128)
It's a shame really that Microsoft wont officially bless ntdll because it's a much more sensible API generally speaking. Like why the hell did they throw away the return value and make everyone do the insane BOOL ret = Win32Function(); if(!ret) { DWORD err=GetLastError(); } dance?
Re:Four Months of Zig on Wednesday October 28, 2026 @08:41AM (#50272660)
But instead you bloat up every call site with an extra argument that needs to be passed, which takes up a few bytes of instructions + claiming a register for it which could have been used for other arguments (and having the allocator in a register is probably a waste since it's a hopefully rare thing to need to access).
Re:Four Months of Zig on Wednesday October 28, 2026 @06:25AM (#50271354)
>And how do you size the arena?

Should you allow an http-server to allocate unbounded request sizes? Seems like it would lead to an easy denial of service.