just spent the last 2 hours debugging a mystery segfault and it turns out it was a stupid null pointer deref caused by a "optimization" from some lazy dev who thought they could just cast a void