Apparently, line counts differ with expansions. The index doesn't look up header files that don't include functions but macros.
I guess actually the difference would come from the behavior difference between getCoverageForFile (source view) and getCoverageForFunction (reports and indices).
I think the index should use getCoverageForFile.