Skip to content

Commit af4235b

Browse files
author
Deepika
committed
Internal members of std::FILE are not available from IAR8.x
1 parent fd4639b commit af4235b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

platform/mbed_retarget.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -839,7 +839,7 @@ std::FILE *mbed_fdopen(FileHandle *fh, const char *mode)
839839
}
840840

841841
int mbed_getc(std::FILE *_file){
842-
#if defined (__ICCARM__)
842+
#if (defined (__ICCARM__) && (__IAR_SYSTEMS_ICC__ < 8) )
843843
/*This is only valid for unbuffered streams*/
844844
int res = std::fgetc(_file);
845845
if (res>=0){
@@ -854,7 +854,7 @@ int mbed_getc(std::FILE *_file){
854854
}
855855

856856
char* mbed_gets(char*s, int size, std::FILE *_file){
857-
#if defined (__ICCARM__)
857+
#if (defined (__ICCARM__) && (__IAR_SYSTEMS_ICC__ < 8))
858858
/*This is only valid for unbuffered streams*/
859859
char *str = fgets(s,size,_file);
860860
if (str!=NULL){

0 commit comments

Comments
 (0)