LNK2019 unresolved external symbols in the symbol is referenced in the function _main

Yan Wei Min learn the data structure, the use of vc6 new project, the file names are as follows:

SequenceStack.cpp

SequenceStack.h

Status.h

TestCase.c

Given as follows:

xilink6: executing 'D:\PROGRA~2\vc6.0\VC98\Bin\link.exe'
TestCase.obj : error LNK2001: unresolved external symbol _InitStack_Sq
Debug/03_01_SequenceStack.exe : fatal error LNK1120: 1 unresolved externals

All the code is correct. Later found the cause, caused by file name, like the TestCase.c into TestCase.cpp

Because the default cpp c ++, c use asni c, c ++ guess it should be and c cdecl (c language calling conventions) Export function declared inconsistent manner, for example c ++ exported functions ??? @ xyz @ Init, c but can not find.

 

Guess you like

Origin www.cnblogs.com/passedbylove/p/11343654.html