Prevent a heading from ending on an escaped #