Some pure functions have impure code
two examples I found while checking this out were smartlist_string_num_isin() which calls tor_snprintf(), which isn't defined as pure. And some other pure functions use tor_assert(), which does file IO. If I understand this correctly, pure functions shouldn't be allowed to call impure functions nor do IO.
unfortunately, GCC only treats this as a hint to the optimizer, and doesn't check to see if it makes sense.
Thanks to [4ZM] who brought up pure functions in #tor-dev :)