`RewindBlockIndex` was made to allow nodes upgrading to new consensus rules post-segwit fork to 
download new consensus data (i.e witnesses) without having to go through a whole IBD. It has been pointed than now really few pre-segwit nodes care to upgrade and that this logic may be irrelevant.

See https://github.com/bitcoin/bitcoin/pull/17737#discussion_r358514335 in review  of #17737 for more context pointers.
LOCK(::cs_main);
    
    
    
    
    
    
    
    
    CBlockIndex* index = nullptr;
    for (int i = 0; i <= snapshot_chainstate.m_chain.Height(); ++i) {
        index = snapshot_chainstate.m_chain[i];
        if (!index->nTx) {
            index->nTx = 1;
        }
        index->nChainTx = index->pprev ? index->pprev->nChainTx + index->nTx : 1;
        
        
        if (index->pprev && ::IsWitnessEnabled(index->pprev, ::Params().GetConsensus())) {
            index->nStatus |= BLOCK_OPT_WITNESS;
        }
    }
    assert(index);
    index->nChainTx = metadata.m_nchaintx;
    snapshot_chainstate.setBlockIndexCandidates.insert(snapshot_start_block);
    LogPrintf("[snapshot] validated snapshot (%.2f MB)\n",
        coins_cache.DynamicMemoryUsage() / (1000 * 1000));
    return true;
}
CChainState& ChainstateManager::ActiveChainstate() const