wchar.h and MQX IO incompatibility

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

wchar.h and MQX IO incompatibility

Jump to solution
816 Views
jessg_
Contributor II

Hi all,

Working with uVision IDE, I want to use the standard library "wchar.h" provided by Keil because I need functions to process wide character strings in my project.

I can not include "wchar.h" and MQX file "fio.h" in the same project because it causes compiler errors like this:

In "fio.h", it has been defined:

typedef MQX_FILE FILE

But in "wchar.h":

      typedef struct __FILE FILE

Both "fio.h" and "wchar.h" are necessary... I know I could edit "wchar.h" file, but I am not sure of modifying standard libraries is the best way...

So, any ideas? What would you do if you were me?

0 Kudos
1 Solution
484 Views
c0170
Senior Contributor III

Hello Jesicca Garcia,

I believe there are more errors which you have not included in your post. There might be a way, if possible to disable "features" which MQX redeclare, like FILE redeclaration : Use macro __ARM_WCHAR_NO_IO to disable FILE redeclaration and I/O function prototypes.

Regards,

MartinK

View solution in original post

0 Kudos
1 Reply
485 Views
c0170
Senior Contributor III

Hello Jesicca Garcia,

I believe there are more errors which you have not included in your post. There might be a way, if possible to disable "features" which MQX redeclare, like FILE redeclaration : Use macro __ARM_WCHAR_NO_IO to disable FILE redeclaration and I/O function prototypes.

Regards,

MartinK

0 Kudos