How C ++ CLR works with iso c ++

Source: Internet
Author: User
Tags microsoft video

I have been using C ++ CLR for a long time and finally understood the differences between ISO C ++ and C ++ CLR, let me briefly describe the pain and gains in my learning.

By studying WinForm programming, I strictly say that I am not WinForm programming, because my original program has a large number of ISO C ++, I can't afford to use C ++ CLI for programming. At the same time, it took me a long time to understand the differences between ISO C ++ and C ++ CLR, at the same time, because the books translated in China are too slow, the C ++ clr I see is the old Syntax of VS2003, while the Microsoft Video downloaded online is VS2005, many of the syntax rules have become completely unrecognizable. I finally found a VS2005 Chinese ebook on the Internet, so I understood the difference between the two, and in 2005, I think it's cool, but I can't say it's more weird ^ (tracking handle). The legendary tracking handle can be said to be really painful.

What's even more painful is that the weird Syntax of C ++ CLR is not mentioned. The worst thing is that I want to use my previous classes and the winform interface. In the. net class library, the FileStream stream, MemoryStream, and ADO.net involve declaring hosted objects in an unmanaged class, so the more weird syntax gcroot <> is coming out, and a variety of weird errors come out. Almost every five lines of programs I write will report errors during compilation, which is really a vicissitudes of life. It can be said that at the time I thought that the most stupid part of the Microsoft department was writing C ++. net compiler, this group of people, how to write such a troublesome thing, in the unmanaged code and managed code, often such a strange error, also in *, ^, and in common value variables, this transformation process is really extraordinary.

Gains:

Although the transformation process is painful, it is worthwhile to look back. Net platform will be the mainstream in the future. At the same time, due to WinForm writing, I learned its event message response mechanism, "delegate ", I have a deep understanding of this concept that can be seen in a soft engineering textbook.

The first achievement is that I finally understood what is "reference type" and "numerical type". I have never understood where java is better than C ++, the conversion and back-and-forth references in many "value types" and "reference types" are values and ref, and finally understand what is going on. It seems that C # and Java have become the mainstream, it's not a waste of false names ".

Tip 2: Through this painful transformation, I feel lucky. Despite the coincidence, I finally learned about the existence of C ++ CLR and finally how to manipulate it. Net class library. It will be good for future job search.

Tip 3: In the course of so hard learning C ++ CLR, this time I am a small programmer who experienced what is "Learning" and what is hard. I used to think that it is difficult to take a postgraduate entrance exam, but I found that "research" is really hard. After all, the postgraduate entrance exam only needs to follow the direction. It can be said that you don't have to work hard, but the research is different, when you think about the problem in multiple ways, you can find that the problem is so simple that it makes you laugh and laugh, but the process of searching is quite complicated.

Here I leave two books and a video that I think are better at. I recommend them to programmers who need transformation just like me.

1: The mfc application is in. Net Framework extension this book describes how to use it in mfc. Net class library. I think this book is very good. . Net class library has all its features highlighted, but the only drawback is that its syntax is still vs2003.

2: visual C ++ 2005 entry-level classic, this book is recommended to me by an online expert, I have not bought it, only the electronic version, but this book puts C ++ in vs2005

The CLR syntax is very thorough. At the same time, the syntax of iso c ++ is a good book on principles.

3: visual c ++. net this book is also very good, winform programming has introduced a lot, especially I have learned a lot of GDI + knowledge, haha, however, it is a pity that the syntax I borrowed is also vs2003.

4: The last one is the online Microsoft Video, which is the vs2005 mentioned by Li Jianzhong. This allows us to better grasp vs2005 C ++ CLR.

The above is my learning experience. I hope you will see less detours and more exchanges with programmers who are in the same transformation as me, so that you can make better progress.

The last thing I want to talk about is that even though I think C ++ CLR is very "chicken", I still want to say that the name of tracking handle is really "cool ", for this reason, I also need to study hard. Just like orc in war3, Grubby, a generation of beowers, is helpless, but since I have chosen a race, we must stick to it, just like the current orc, there will always be a day when we are strong. Haha, I look forward to it.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.