There's a solid explanation for why this happened. The Demon saw the Slayer, went through a quick existential crisis, the seven stages of grief, and spiritual enlightenment all in the matter of one second. He then died of a heart attack when the heavy metal that radiates around The Slayer got closer to him.