A high-level, general-purpose programming language, created as an extension of the C programming language, that has object-oriented, generic, and functional features in addition to facilities for low-level memory manipulation.
IgorTandetnik-1300 avatar image IgorTandetnik-1300 · 10 hours ago
It seems that you haven't provided a declaration for cppfunc in your C program. Absent a declaration, C compiler assumes int return value (whereas C++ compiler complains; C++ doesn't allow calling undeclared functions). So basically the caller takes whatever random garbage happens to be sitting in EAX register after cppfunc returns, and assumes it to be the function's return value (the actual return value is sitting on the FPU register).
0 Votes0 · Reply More
It works. I appreciate you.