Not a glitch at all.
From the wiki:
For example if you had 4 Coin, you lose the 4 Coin and draw 4 cards. This makes you lose all Coin you have so far that turn, including the Coin you get from playing the Treasures, the +1 Coin Storyteller gives you directly, and any Coin you made earlier in the turn.