lnk2022

LNK 2022: Inconsistent layout information, after migrating to VS2010

自古美人都是妖i 提交于 2019-12-12 16:09:02
问题 I have a VS2010 solution that contains (among others), the following projects: Native.DLL (native C++ project that statically links to a third party lib, ITK, which includes STL) Pseudo-code (very simplified): using namespace std; bool Native::CalcSomething(double* result, string& errorMsg); Wrapper.DLL (C++/CLI project that dynamically links to Native.DLL and uses std:string in a call to the Native.DLL) Pseudo-code (very simplified) bool Wrapper::WrappedCalcSomething([System::Runtime:

LNK2022: metadata operation failed : Inconsistent field declarations in duplicated types

此生再无相见时 提交于 2019-12-07 04:15:34
问题 I have problem with compiling my C++ .NET project. I have read "LNK2022: metadata operation failed" driving me insane -- and this is not my case, because in my case i cannot compile one single project -- it fails at link time. i tried all (two) solutions from that topic and that didn't help me. This errors started to rise up just when i have changed the class to be a template class. i have Vector2Di (for int type) class and now need completely the same for float type, so i renamed it to

LNK2022: metadata operation failed : Inconsistent field declarations in duplicated types

穿精又带淫゛_ 提交于 2019-12-05 11:18:31
I have problem with compiling my C++ .NET project. I have read "LNK2022: metadata operation failed" driving me insane -- and this is not my case, because in my case i cannot compile one single project -- it fails at link time. i tried all (two) solutions from that topic and that didn't help me. This errors started to rise up just when i have changed the class to be a template class. i have Vector2Di (for int type) class and now need completely the same for float type, so i renamed it to Vector2D and changed it to use template, now i have: template <class T> public ref class Vector2D :