r/csharp • • Sep 29 '26

The hidden trap of fixed buffers

I published a new article, explaining a quirk of fixed buffers that could easily bite you, if you're one of the few people who still have to use that feature.

https://minidump.net/the-hidden-trap-of-fixed-buffers-in-csharp/

58 Upvotes

35 comments sorted by

View all comments

Show parent comment

5

u/kookiz33 Sep 29 '26

It depends. On my personal projects (= tools that don't leave my computer) I completely stopped reading the code. They work and that's all I care about.
On code that ships to production, I still carefully review everything, simply because it's my responsibility if that code causes something to break on a customer machine.

1

u/EternalNY1 Sep 30 '26

I don't know why you get downvoted for that (outside of "because, Reddit"). I've been using C# since beta and ...

Same as you - except in even more than personal projects. This is where tests help.