I am trying to place a very dimly-remembered scene from a book — which I think was sci-fi/fantasy, though I'm not even 100% sure of that.
Some character is seen bowing out of the main action — I think in a slightly suicidal way, making a last stand against enemies to buy the main group some time, or something. And as she (I think the character was female, but again, I'm not certain) goes, we and the remaining protagonists hear her singing (possibly over a ship's intercom, or something like that) the song
"When you walk through the storm / Hold your head up high / And don’t be afraid of the dark…"
What is the name of this book?