make boolean option parsing (more) self-contained