user2152780
user2152780

Reputation: 53

Weird error in IAR EWARM "Error[Pe147]: declaration is incompatible with "__interwork __softfp"

I'm getting this error that goes beyond my knowledge :

Error[Pe147]: declaration is incompatible with "__interwork __softfp char *Get_Language_String(enum Lang_Index, enum String_Index)" (declared at line 26 of "E:\Freescale\Freescale_MQX_4_0\demo\ E:\Freescale\Freescale_MQX_4_0\demo\DialogD13_Demo_v5\Strings.c 79 

DialogD13_Demo_v5\Strings.h")

I have this in my code :

strings.h:
extern char *Get_Language_String(enum Lang_Index Lang_Ind, enum String_Index Str_Ind);

strings.c:
char *Get_Language_String(enum Lang_Index Lang_Ind, enum String_Index Str_Ind)
{
  return languages[Lang_Ind][Str_Ind];
}

What is wrong ?

Thanks in advance,

regards, Bul.

Upvotes: 0

Views: 5426

Answers (1)

user2152780
user2152780

Reputation: 53

thanks for response...

It was order of definitions that caused this error.

extern clause in strngs.h was before definitions of enums...

Regards,

Bulek.

Upvotes: 1

Related Questions