Mysterious Keywords

This one is a classic. In Erlang, both keywords and atoms are written as lowercase words (well… atoms can also be written within single quotes, but let’s forget about that for a bit). Most of the times, that’s not an issue: you know that if is a keyword, case is a keyword, my_function is not, etc.

But there are a few reserved words that are not actually keywords (in the sense that you can’t build expressions with them) but they’re also not atoms. They’re just reserved for the future. A while back (before OTP17) the one that everybody stepped over was query. Since then, you can finally write a function called query, but 2 other magic keywords still remain. Let’s see if you can spot them by comparing the list of reserved words here with the list of valid expressions here ;)