| 52 | |
| 53 | template<typename EquivType> |
| 54 | void updateScript(std::true_type, EquivType type, const blocksci::State &state, const blocksci::ScriptAccess &scripts) { |
| 55 | auto typeIndex = static_cast<size_t>(type); |
| 56 | auto progress = blocksci::makeProgressBar(state.scriptCounts[typeIndex] - latestState.scriptCounts[typeIndex], [=]() {}); |
| 57 | uint32_t num = 0; |
| 58 | std::cout << "Updating index with scripts of type " << dedupAddressName(type) << "\n"; |
| 59 | for (uint32_t i = latestState.scriptCounts[typeIndex]; i < state.scriptCounts[typeIndex]; i++) { |
| 60 | static_cast<T*>(this)->template processScript<type>(i + 1, scripts); |
| 61 | progress.update(num); |
| 62 | num++; |
| 63 | } |
| 64 | } |
| 65 | |
| 66 | template<typename EquivType> |
| 67 | void updateScript(std::false_type, EquivType, const blocksci::State &, const blocksci::ScriptAccess &) {} |
no test coverage detected