diff --git a/include/layers_id_colors_and_visibility.h b/include/layers_id_colors_and_visibility.h index 7dc0660457..5df67215be 100644 --- a/include/layers_id_colors_and_visibility.h +++ b/include/layers_id_colors_and_visibility.h @@ -245,18 +245,6 @@ enum PCB_VISIBLE END_PCB_VISIBLE_LIST // sentinel }; -#ifndef NDEBUG -struct static_check { - static_check() - { - // Long (the type used for saving visibility settings) is only 32 bits guaranteed, - // be sure that we do not cross the limit - assert( END_PCB_VISIBLE_LIST <= 32 ); - }; -}; -static static_check check; -#endif - /** * Enum NETNAMES_VISIBLE * is a set of layers specific for displaying net names. diff --git a/pcbnew/class_board_design_settings.cpp b/pcbnew/class_board_design_settings.cpp index e98dc81ef1..654ca11653 100644 --- a/pcbnew/class_board_design_settings.cpp +++ b/pcbnew/class_board_design_settings.cpp @@ -243,3 +243,16 @@ void BOARD_DESIGN_SETTINGS::SetEnabledLayers( LAYER_MSK aMask ) // update m_CopperLayerCount to ensure its consistency with m_EnabledLayers m_CopperLayerCount = LayerMaskCountSet( aMask & ALL_CU_LAYERS); } + + +#ifndef NDEBUG +struct static_check { + static_check() + { + // Int (the type used for saving visibility settings) is only 32 bits guaranteed, + // be sure that we do not cross the limit + assert( END_PCB_VISIBLE_LIST <= 32 ); + }; +}; +static static_check check; +#endif