6 ms·
I'm pretty sure that use of 'xxx' predates computers as a stand-in for "some stuff". Like a Kleene star before regex existed. To me it seems uninteresting, and
by dahart 10y ago
I'm pretty sure that use of 'xxx' predates computers as a stand-in for "some stuff". Like a Kleene star before regex existed.
To me it seems uninteresting, and perhaps even misleading, to try and find the 'first use of xxx' on computers.
I started using "XXX TODO" in college 20 years ago and I don't remember ever seeing it anywhere, it was a natural thing to do. I occasionally had "todo" in comments and code I wanted to fix very soon, and adding the 'XXX' was the easiest thing to add to make it searchable with no false positives. For whatever reason it seemed like an obvious thing to do. It's possible I picked it up somewhere, but I wasn't reading much code, there was nowhere near the access to public repos then that there is now. I'm pretty sure I invented it independently along with many other people.
> Why he chose to switch to the rather inconvenient XXX from ### is unclear.
I don't understand this comment... XXX is easier to type than ###. Caps lock works for X's and not for #'s. Even when using the shift key, X is a shorter throw than #.
- evgen 10y agoXXX is also easy to recognize visually in printed text. It stands out well and through convention it has become clearly recognizable as such a placeholder.
- mikerg87 10y agoI first saw as a it in drafts of memos and reports when such items were circulated on paper through cubby holes. This was Long before I saw it applied to source code - say '73-75 time frame.
- jsnell 10y agoThe inconvenient part of XXX are the false positives when searching. I don't buy the independent discovery idea (despite also thinking at one point that XXX was just my personal convention). When you pick up something through osmosis, you don't remember the exact source where you learn from. If this really was something that programmers just do naturally rather than learn, the programmers of the '60s and '70s would have been doing it too, and there should be some traces of it in the record. But at least I can't find those traces.
- dahart 10y ago> I don't buy the independent discovery idea That's fair -- and like I said it could have happened. If I did pick it up, I'd be willing to bet it came from print sources and not computer sources. Using Xs as a placeholder is absolutely commonplace. But I remember sitting at my computer and searching for TODO, and then trying a few things before settling on XXX TODO. I tried "TODO TODO" and "(asterisk)(asterisk)TODO(asterisk)(asterisk)" and stuff like that... XXX TODO was simpler to type and easier to see. What I don't really buy is that this is a "discovery" at all. This doesn't seem worthy of attribution as a thing, not as a meme or as something that stands out as particularly useful or particularly widespread either. There are a bunch of conventions for TODO comments, and XXX isn't everywhere by any stretch. The kind of thing that I know I picked up elsewhere is 0xDEADBEEF, and that's the kind of thing that feels more worthy of investigation & attribution to me.
- pvg 10y agoI'm actually pretty convinced of multiple independent 'discovery'. The available annotated historical record we get to look at is tiny and drawing conclusions from it seems almost as problematic as doing the same from personal memory.
- JCzynski 10y agoI didn't read much existing codebases and started doing it myself. I probably stuck with it because vim does visual highlighting of TODO/XXX/FIXME/etc., but I definitely picked it as a searchable "I'm not going to reuse this string of characters" marker.
- slizard 10y ago> The inconvenient part of XXX are the false positives when searching. Would you mind elaborating what kind of source code contains numerous triplets of the uppercase character "X" and why? I have never seen such code other than produced by extremely inexperienced programmers/students with no imagination to naming symbols and ending up with "x", "xx", "xxx" variable names; even those cases will most likely not be all uppercase.
- odonnellryan 10y agoI remember using asterisks for this instead of XXX or ###.
- cpeterso 10y ago> Why he chose to switch to the rather inconvenient XXX from ### is unclear. then why didn't Bill Joy replace his ### comments with XXX in that commit? Now he has to search for both ### and XXX. That suggests he might have been using ### and XXX as warning comments, not grep breadcrumbs.