Type matching for booleans and integers