Fix strrchr() not declared for IAR

For IAR, strrchr() is used in MBED_FILENAME macro definition. Declare it via string.h to fix compile error when MBED_FILENAME is expanded.
pull/15222/head
Chun-Chieh Li 2022-02-07 16:04:23 +08:00
parent 9bdbe9cb85
commit 9e49cabb2c
1 changed files with 5 additions and 0 deletions

View File

@ -33,6 +33,11 @@
#endif
#endif
/* Fix strrchr() not declared for IAR, used in MBED_FILENAME */
#if defined(__ICCARM__)
#include <string.h>
#endif
// Warning for unsupported compilers
#if !defined(__GNUC__) /* GCC */ \
&& !defined(__clang__) /* LLVM/Clang */ \