Fast and tiny helper to check argument (or array element) types