they cause list item to be outside lists. This is because BEGIN_SECTION events are produced before headers, but the corresponding END_SECTION come after the lists. A fix consists in generating END_SECTION events before closing the list item, and then ignoring the corresponding number of END_SECTION that will come after, effectively moving the END_SECTION events at the right place |