AnsweredAssumed Answered

LL function causes compiler warning

Question asked by T B on Dec 18, 2017
Latest reply on Feb 28, 2018 by Imen D

Hi!

 

The LL library causes a compiler warning (dereferencing type-punned pointer; see below).

Can I ignore this warning?

 

-Thomas

 

/STM32Cube_FW_F3_V1.9.0/Drivers/STM32F3xx_HAL_Driver/Inc/stm32f3xx_ll_crc.h:355:3: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]


__STATIC_INLINE void LL_CRC_FeedData16(CRC_TypeDef *CRCx, uint16_t InData)
{
*(uint16_t __IO *)(&CRCx->DR) = (uint16_t) InData;
}

Outcomes