Trying to put inline functions in external file within project, and getting below errors.
If I remove "__forceinline", then all is well.
If I have the inline function in main cpp file and not in header, it is fine also.
Is there a procedure to deal with this?
file.h
__forceinline __int64 Parse(const unsigned char *);
file.cpp
__forceinline __int64 Parse(const unsigned char * parsearray){
//nothing special
return 0;
}
error LNK2001: unresolved external symbol "__int64 __cdecl Parse(const unsigned char *)"
fatal error LNK1120: 1 unresolved externals
(edit)
I am aware that __forceinline does not mean the compiler (vs2010) will inline it.