The compiler isn't smart enough to figure all of these out, so restructure things a bit to avoid warnings.