This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

what is (void)dummy? nRF52840 SDK 14.0

Hi there,

I came across the function call "(void)dummy;" which I am trying to locate. Where can I find this?

__STATIC_INLINE void nrf_rtc_event_clear(NRF_RTC_Type * p_rtc, nrf_rtc_event_t event)
{
    *((volatile uint32_t *)((uint8_t *)p_rtc + (uint32_t)event)) = 0;
#if __CORTEX_M == 0x04
    volatile uint32_t dummy = *((volatile uint32_t *)((uint8_t *)p_rtc + (uint32_t)event));
    (void)dummy; //puru: what is this? Is it calling some special function?
#endif
}

I think this will execute as it is a CortexM4 processor. And if yes then what function will it call? where is it located? Also what I observe is the first line is assigning the value as "0".

Am I interpreting it correctly?

Thanks!

Parents Reply Children
No Data
Related