Search Results

Search found 3 results on 1 pages for 'coanor'.

Page 1/1 | 1 

  • How to use a object whose copy constructor and copy assignment is private?

    - by coanor
    In reading TCPL, I got a problem, as the title refered, and then 'private' class is: class Unique_handle { private: Unique_handle& operator=(const Unique_handle &rhs); Unique_handle(const Unique_handle &rhs); public: //... }; the using code is: struct Y { //... Unique_handle obj; }; and I want to execute such operations: int main() { Y y1; Y y2 = y1; } although, these code are come from TCPL, but I still can not got the solution... Can anybody help me, appreciate.

    Read the article

  • dll runtime error(C/C++/GCC/MSVC)

    - by coanor
    After two days fighting, I make the dll(compiled in GCC/G++) link correctly in MSVC, but while debuging, I got the runtime error, is say that: Runtime Error! Program: my_exe.exe This application has required the Runtime to terminate it in an unusual way. Please contact the application's support team for more information. I have test something in that way: compiled a dll in mingw/gcc, link and debug in MSVC, it works correctly ,but while I implement it in my large project, I got the runtime error. And I tested the dll in mingw/GCC, it works correctly, it says that the runtime error does not come from programming error,it comes from the dll imcompatible between different platform. Does anyone can hele me? Thanks, forgive my poor English.

    Read the article

  • In C/C++,how to link dynamic link lib which compiled in GCC/G++ in MS VStudio?

    - by coanor
    These days, I use Flex & Bison generated some codes to develop a SQL-parser alike tools, these code can't compiled silently(may be this another topic) in VS2005,but GCC/G++ works well, then I compiled these code with mingw in dll(in windows xp), and then linked these function facades in VS2005, but it seems can't link the dll during linking. Does MS VS2005 recognize the dll which compiled using mingw on windows? Is there anything I need to do additional? For example, adding something in the include-file that declare the exported APIs? Does any one can give some advices? The condition is, as in VS2005, if you want to export some APIs, you may show a *.def file to tell nmake which API you want to export, and then you may create a(or some) *.h file to declare somthing about these APIs(adding some stdcall alike prefix as a call protocal) and some data-type definition. But with GCC/G++, you do not need to do such boring things, just use [ar], you can get these APIs, so my *.h file do not add call protocol and no *.def, just like common function declaration. After *.dll generated, add the *.h file and [mv] generated *.dll in VS2005 project directory, then set the linking *.dll in project setting. Does these steps generated my Question? BTW, I found and tested VC6-compiled dll can be linked with mingw in Windows XP, but the reverse can't work. Anyway, forgive my poor English, and thanks for your concern.

    Read the article

1