starts when cold. dies when stopping and will not start until cools off. on 1994 Mazda B3000

starts when cold, but when stopping or slowing down, trys to go back to idle and dies. will not start again until cool. also idles at 2200 rpm when first started

Asked by for the 1994 Mazda B3000
Sounds like its the coil. mine did the same thing and i changed the coil, now it starts fine.