mirror of
https://github.com/status-im/nimbus-eth2.git
synced 2025-02-02 17:53:52 +00:00
2bbffbde10
There are a few locations in the code that compare the current epoch to the various FORK_EPOCH constants and branch off into fork-specific code. When a new fork is introduced, it is sometimes forgotten to update all of those branch locations. This patch introduces a compile-time check that ensures that all branches need to be covered exhaustively. This is done by replacing if-elif structures with case expressions.