Also "allow-list" is so gross. Maybe pick something less divisive for future examples.
Also "allow-list" is so gross. Maybe pick something less divisive for future examples.
I agree. Just because it can be misused does not mean it is no good for anything. Note that you can declare types explicitly, and is usually how I do when I write anything in Haskell anyways, which makes the program clearer.
Also, changing the types after the rest of the program is already written, is going to be a problem in any programming language even without ad-hoc polymorphism, if you do not then consider everything that needs to be changed due to that.
> Also "allow-list" is so gross. Maybe pick something less divisive for future examples.
I agree with this, too. You can call it "allowed clients" or "list of allowed clients" if you want to, which is better in my opinion. (Simply "allow-list" does not even describe very well what it is for; what is being allowed?)
What is gross or divisive about that?
Reminds me of "mebi-byte", which is similarly gross (but at least that had sensible motivation).
However, just because a word is OK does not mean it is applicable to all contexts. You can call the list "AllowedClients" or something else like that instead, which explains what is being allowed (since there might be multiple kinds of restrictions that you might wish to define based on lists). (Of course, this is a whitelist mode, and can be described as such.) However, if the program already exists, then changing the name of the setting would be even worse (unless the old name is still available as an alias, but you must be careful to ensure you do not mess up anything by doing so), since that would just break compatibility (you can change the documentation though if the existing documentation is unclear).
Also, in some contexts a word can be confusing and a different word is preferable. For example, if the list has something to do with colours, then using the terms "whitelist" and "blacklist" might be confusing and perhaps should not be used. Likewise, singular "they" is OK, but if singular they is confusing in that context then you should use different words instead.
Still, if some people do not like "whitelist", you do not have to use it, but you should consider what words to use which are appropriate and descriptive. Fortunately, sometimes they do, but unfortunately sometimes they don't because their only consideration is to be not racist, instead of to actually be good.
I also do not like the word "tonne"; I prefer "megagram" (which is more descriptive, just as easy to understand, and not confused with "ton").
https://httpd.apache.org/docs/2.4/mod/mod_access_compat.html...