RSSAmplifier

Blog

Trez’ blog

Stuff that I find nifty.

mynameistrez.github.ioRSS feed ↗10 posts

Latest posts

The LuaJIT NYI That Silently Poisoned an Unrelated Hot Loop

I wrote the blog post The LuaJIT NYI That Silently Poisoned an Unrelated Hot Loop for the company I work at, check it out!

Slow is smooth, smooth is fast

Slow is smooth, smooth is fast is a neat phrase, but it is usually explained incompletely. People say: go slow, avoid mistakes, save time overall. That is true, but it misses why we rush in the first place.

Comptime C functions

Compile-time function execution is great, as it means your program has to run less code at runtime, but what if: You’re stuck with C. You don’t want to use evil C macros, as they are debugging nightmares. You want data structures that work for all types, and that can use malloc() and free() internally.

Allocationless C89 JSON parser

I wrote the library Allocationless C89 JSON parser. See its readme. Enjoy! 🙂

How grug used to catch runtime errors

Make sure to read my previous post first called Creating the perfect modding language, since it goes over the basics of grug.

Static C/C++ analysis with PVS-Studio

This blog post goes over how a student can statically analyze their C/C++ code with PVS-Studio for free on Ubuntu.

Array-based hash table in C

Why hash tables are incredibly useful

For the love of god, only call srand() once

One of the most common C mistakes I’ve seen is to call srand(time(NULL)); right before using rand() to generate a random number:

How to process a request like nginx does

After having helped a handful of people with the project, I’ve decided to write this blog post about my webserv project I did 4 months ago at Codam.

Static arrays are the best vectors

What if I told you that C has a built-in vector?