Just pointing this out about Lan: RJ meant him to be a parallel to Lancelot du Lac, his background, his kingdom, etc., are part of this.
Likewise, Demandred is a parallel to Mordred. In the Arthurian legends, Mordred faces Arthur and they kill each other. Sometimes it is Lancelot (Lan) who fights Mordred, and THEY kill each other. So, since Arthur (Rand) is in Shayol Ghul, it's up to Lancelot (Lan) to take out Mordred (Demandred).
Now, I agree with Brandon. Lan SHOULD have died, and "technically" did...until Rand pulled his "vis major" (act of god) and gave him enough of a life force that Narishma was able to Heal him enough to keep him from dying until he was taken to an actual Channeler who could do better.
So, in the sense of carrying on with the Arthurian-theme RJ used throughout the series, Lan's "Sheathing the Sword" makes perfect sense.