mirror of https://github.com/ARMmbed/mbed-os.git
				
				
				
			Remove `statement is unreachable` warning in MbedCRC.h
The code removed appears unnecessary given that the switch case below also handles the case where the polynomial is `POLY_32BIT_REV_ANSI`pull/11478/head
							parent
							
								
									01bb1b94d7
								
							
						
					
					
						commit
						5bfb5bf269
					
				| 
						 | 
					@ -514,22 +514,19 @@ private:
 | 
				
			||||||
        MBED_STATIC_ASSERT(width <= 32, "Max 32-bit CRC supported");
 | 
					        MBED_STATIC_ASSERT(width <= 32, "Max 32-bit CRC supported");
 | 
				
			||||||
 | 
					
 | 
				
			||||||
#if DEVICE_CRC
 | 
					#if DEVICE_CRC
 | 
				
			||||||
        if (POLY_32BIT_REV_ANSI == polynomial) {
 | 
					        if (POLY_32BIT_REV_ANSI != polynomial) {
 | 
				
			||||||
            _crc_table = (uint32_t *)Table_CRC_32bit_Rev_ANSI;
 | 
					            crc_mbed_config_t config;
 | 
				
			||||||
            _mode = TABLE;
 | 
					            config.polynomial  = polynomial;
 | 
				
			||||||
            return;
 | 
					            config.width       = width;
 | 
				
			||||||
        }
 | 
					            config.initial_xor = _initial_value;
 | 
				
			||||||
        crc_mbed_config_t config;
 | 
					            config.final_xor   = _final_xor;
 | 
				
			||||||
        config.polynomial  = polynomial;
 | 
					            config.reflect_in  = _reflect_data;
 | 
				
			||||||
        config.width       = width;
 | 
					            config.reflect_out = _reflect_remainder;
 | 
				
			||||||
        config.initial_xor = _initial_value;
 | 
					 | 
				
			||||||
        config.final_xor   = _final_xor;
 | 
					 | 
				
			||||||
        config.reflect_in  = _reflect_data;
 | 
					 | 
				
			||||||
        config.reflect_out = _reflect_remainder;
 | 
					 | 
				
			||||||
 | 
					
 | 
				
			||||||
        if (hal_crc_is_supported(&config)) {
 | 
					            if (hal_crc_is_supported(&config)) {
 | 
				
			||||||
            _mode = HARDWARE;
 | 
					                _mode = HARDWARE;
 | 
				
			||||||
            return;
 | 
					                return;
 | 
				
			||||||
 | 
					            }
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
#endif
 | 
					#endif
 | 
				
			||||||
 | 
					
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
		Reference in New Issue