more rigid check for Netmask.constructor