Originally Posted by kovidgoyal
I'm a little confused by the toc type index entries. Since you aren't writing them to the MOBI Index header and you're ignoring them during the creatin of the TBS, why are you generating them at all?
Those toc type index entries ensure that the index entries for the sections have an offset and length that includes the inline section TOC that is inserted into the markup. Without them, I believe the index entries for the sections would have an offset at the beginning of the first article in the section, not the TOC, and the section length would not include the TOC.