Factor, Don’t Complicate

A reader asks the following question,   Sender: bv   re: A Question about Copy Constructors in C++/CLI   Ok, i have a question. What happens if: suppose you want to make a shallow copy. Ex:   ClassX obj(somePtr);//internally obj.m_ptr = SomePtr;   Now   ClassX obj2(obj);   What problems can occur in such cases?…

7

Putting C++ and the CLI in Perspective

A surprising thread that has emerged has to do with libraries. Here is an representative example,   Sender: Dobes =====================================   re: Towards a Natural Theory of Programming Languages   I also think that the survival of a language is also more an issue of libraries than of language.    I prefer Java because it…

6

System::String -> std::string

A reader asks,   Sender: Erik Brendengen   Is there an easy way to convert from String^ to std::string?              Does String ^s = std::string( “bla”).c_str(); work the other way?   This is a FAQ, one that I myself bumped into when I had to pass a System::String retrieved from System::Windows::Forms::TextBox to a native program…

8

A Question of Interopt

A reader asks the following question,   Sender: Richard Hsu Stan,   Would you suggest, for those of us who are yet to begin learning MC++, to wait till C++/CLI ships, because we’ll not only be learning what will be obsolete syntax, but also a more difficult one.   So, would you recommend, till the…

1