avoid useless warning for 'bool <- restricted type' conversion