david_m_stone's profile picture.

David Stone

@david_m_stone

Here's some C code that prints "Math works" at compile time: ``` #if ((eight + 4) * 12) / (2 + four) == 24 #warning Math works #else #error Math does not work #endif ``` godbolt.org/z/WojM7jbda


David's "Expecto Patronum" did not go as planned.

david_m_stone's tweet image. David's "Expecto Patronum" did not go as planned.

I wish I could filter out all serious tweet responses that begin with any variant of "ChatGPT / Grok / Claude thinks..."


Please stop making json formats that look like ``` { "key": "asdf", "value": "qwerty" } ``` Just do `{ "asdf": "qwerty" }`


Just saw this in ChatGPT's "memory" for me: Prefers not to receive repeated or incorrect answers.


The first version of Catch is "catch". Fedora calls this package "catch". The second version is "catch2". Fedora calls this package "catch2". Fedora then removed support for version 1. The third version is "catch2-v3". Fedora calls this "catch".


Consistency: the idea that if we are mostly wrong about something, we have to keep being wrong about it. The alternative model is the belief that the first step to getting out of a hole is to stop digging a hole.


A website has "Not finding what you're looking for?" with a link to contact them. The link is a 404.


When I paste a document into ChatGPT and ask for feedback it usually focuses on the content. If I first say "I pasted this from a Google doc so the formatting got messed up. Don't comment on that" half of its comments are about the formatting.


Consider the superhero "Percentile Man". He can perform any skill at the Nth percentile of human ability (no better, no worse), and he has a sense for what that means for any skill. How good does he have to be for this to be a superpower?


Is there a site or paper that gives examples of macros that interfere with refactoring tools? Or just drop them in here.


`std::pair` should never be used if `first` and `second` are not the best names for your data members.


In C++ if I have a range of ranges and I flatten them (for instance, `join_view`), how do I efficiently expose the size of the resulting range? If each inner range is sized, getting the size is O(n) in the number of inner ranges but O(?) in the number of elements


Given an input iterator `it`, is it well-defined to do `*it; *it;`? If so, is there an even weaker iterator category that disallows it? If not, is there an even stronger iterator category that allows it without also allowing increment?


Loading...

Something went wrong.


Something went wrong.