Hacker News new | ask | show | jobs
by rolodato 3204 days ago
> e.g. I use the terms "Flag" instead of "Boolean"

I'm not familiar with THT and this is a nitpick, but doesn't this contradict the first principle? Pretty much every language I've ever used has some notion of "boolean", and I don't know one that uses "flag". Don't want to bash, just curious how that decision was taken.

1 comments

Most of the principles are always in tension to some degree, and come down to a design decision. In this case, the shorter, clearer term won out. The two terms are practically synonymous, so if you know what a "boolean" is, you probably know what a "flag" is.

In actual use, you rarely interact with the names anyway -- you use `true` and `false` as values like most other languages.

Flag is a pretty obscure term that you learn from using the linux command line. Booleans are in math and engineering. Flag is not clear at all and using it instead of boolean, especially when you don't even use the term boolean directly all that much, seems kind of silly.