Ha! I made homemade maraschino cherries last year, and the secret ingredient was none other than... almond extract! The cherries tasted great without the extract, but with it, boy oh boy, THAT'S the secret flavor in all the commercially made maraschinos.
The fact of the matter is, both almonds and cherry pits contain cyanide compounds that provide the "cherry" flavor. Almonds develop the flavor more as they age and turn stale. And yes, I said cyanide. In sufficient quantities, either old aged almonds or cherry pits can be poisonous, but only dogs and other small animals might make the mistake of eating way too many -- humans seem too large and intelligent to be affected very much.