Code warrior/OSEK C to C++ conversion

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

Code warrior/OSEK C to C++ conversion

1,974 Views
MIkeX
Contributor I
I have spent many hours trying to get files in C to work fith C++ files to no avail. I start out in C, because the OSEKturbo will only be noticed in Code Warrior that way. I then include C++ files and everything falls apart. The extern "c" {} does not seem to work right either.
 
Are there any ways or tricks to use between files (c to C++) to make them play with each other. Also I am using the Professional version of C.W. which is suppose to work in asm, c, and c++ together
 
 
MikeX
Labels (1)
0 Kudos
Reply
1 Reply

552 Views
CrasyCat
Specialist III
Hello
 
Which processor are you targeting (HC08, HC12, MPC5xx, ...)?
Which version of CodeWarrior are you using?
 
I have used extern "C"  in several occasion and it was working.
Note that extern "C" should be used when you include ANSI C header files in a C++ source file.
Reading your message I have the impression you are trying to do the opposite.
Basically you cannot include a C++ header file in a ANSI C source file.
 
CrasyCat
0 Kudos
Reply