diff --git a/devices/MIMXRT1021/mcuxpresso/startup_mimxrt1021.c b/devices/MIMXRT1021/mcuxpresso/startup_mimxrt1021.c index 379dc971d..362ff24e8 100644 --- a/devices/MIMXRT1021/mcuxpresso/startup_mimxrt1021.c +++ b/devices/MIMXRT1021/mcuxpresso/startup_mimxrt1021.c @@ -19,16 +19,13 @@ #ifdef __REDLIB__ #error Redlib does not support C++ #else -//***************************************************************************** -// -// The entry point for the C++ library startup -// -//***************************************************************************** extern "C" { +#endif +#endif extern void __libc_init_array(void); +#if defined (__cplusplus) } #endif -#endif #define WEAK __attribute__ ((weak)) #define WEAK_AV __attribute__ ((weak, section(".after_vectors"))) @@ -666,12 +663,7 @@ void ResetISR(void) { *pSCB_VTOR = (unsigned int)g_pfnVectors; } #endif // (__USE_CMSIS) -#if defined (__cplusplus) - // - // Call C++ library initialisation - // __libc_init_array(); -#endif // Reenable interrupts __asm volatile ("cpsie i");