"Heater" was an Iotian slang term for "gun" (or, by extension, phasers, described as "fancy heaters"). The Iotians adopted their society to the book Chicago Mobs of the Twenties which described the 20th century Earth culture where the term originated. One well-known brand of heater was Bang Bang.
Montgomery Scott was unfamiliar with the term. After Bela Okmyx contacted the USS Enterprise in 2268 and asked for "a hundred of these fancy heaters you've got, and some troops to show me how to use them" in exchange for the landing party, Scott asked Lieutenant Hadley to look up the term in the Enterprise's language banks. (TOS: "A Piece of the Action")