diff --git a/targets/TARGET_NORDIC/TARGET_NRF5x/TARGET_SDK_15_0/components/libraries/experimental_section_vars/nrf_section_iter.c b/targets/TARGET_NORDIC/TARGET_NRF5x/TARGET_SDK_15_0/components/libraries/experimental_section_vars/nrf_section_iter.c index ea8b02f7a6..288315e5d2 100644 --- a/targets/TARGET_NORDIC/TARGET_NRF5x/TARGET_SDK_15_0/components/libraries/experimental_section_vars/nrf_section_iter.c +++ b/targets/TARGET_NORDIC/TARGET_NRF5x/TARGET_SDK_15_0/components/libraries/experimental_section_vars/nrf_section_iter.c @@ -45,7 +45,7 @@ #include "nrf_section_iter.h" -#if !defined(__GNUC__) +#if !defined(__GNUC__) || defined(__CC_ARM) static void nrf_section_iter_item_set(nrf_section_iter_t * p_iter) { ASSERT(p_iter != NULL); @@ -82,7 +82,7 @@ void nrf_section_iter_init(nrf_section_iter_t * p_iter, nrf_section_set_t const p_iter->p_set = p_set; -#if defined(__GNUC__) +#if defined(__GNUC__) && !defined(__CC_ARM) p_iter->p_item = p_iter->p_set->section.p_start; if (p_iter->p_item == p_iter->p_set->section.p_end) { @@ -106,7 +106,7 @@ void nrf_section_iter_next(nrf_section_iter_t * p_iter) p_iter->p_item = (void *)((size_t)(p_iter->p_item) + p_iter->p_set->item_size); -#if defined(__GNUC__) +#if defined(__GNUC__) && !defined(__CC_ARM) if (p_iter->p_item == p_iter->p_set->section.p_end) { p_iter->p_item = NULL; diff --git a/targets/TARGET_NORDIC/TARGET_NRF5x/TARGET_SDK_15_0/components/libraries/experimental_section_vars/nrf_section_iter.h b/targets/TARGET_NORDIC/TARGET_NRF5x/TARGET_SDK_15_0/components/libraries/experimental_section_vars/nrf_section_iter.h index 2f9be61bea..014c21f702 100644 --- a/targets/TARGET_NORDIC/TARGET_NRF5x/TARGET_SDK_15_0/components/libraries/experimental_section_vars/nrf_section_iter.h +++ b/targets/TARGET_NORDIC/TARGET_NRF5x/TARGET_SDK_15_0/components/libraries/experimental_section_vars/nrf_section_iter.h @@ -68,7 +68,7 @@ typedef struct /**@brief Set of the sections description structure. */ typedef struct { -#if defined(__GNUC__) +#if defined(__GNUC__) && !defined(__CC_ARM) nrf_section_t section; //!< Description of the set of sections. /**< * In case of GCC all sections in the set are sorted and @@ -87,7 +87,7 @@ typedef struct typedef struct { nrf_section_set_t const * p_set; //!< Pointer to the appropriate section set. -#if !defined(__GNUC__) +#if !defined(__GNUC__) || defined(__CC_ARM) nrf_section_t const * p_section; //!< Pointer to the selected section. /**< * In case of GCC all sections in the set are sorted and @@ -110,7 +110,7 @@ typedef struct * @param[in] _count Number of the sections in the set. This parameter is ignored in case of GCC. * @hideinitializer */ -#if defined(__GNUC__) +#if defined(__GNUC__) && !defined(__CC_ARM) #define NRF_SECTION_SET_DEF(_name, _type, _count) \ \