What happened to the MSDN C++ Language Reference? - c++

Around 2007 I remember installing Visual Studio (I don't remember the exact version), which was shipped on CDs in those days. There were some extra CDs in our pack, called I think "MSDN C++ Language Reference" which if you installed them gave you inline language guides - we were using C/C++ then. With these installed you could highlight something in the code and hit a key (possibly F1 I don't remember exactly) and it would bring up a side panel with a great summary of the language feature. This worked for the core language and the standard library. This was a brilliantly fast way of checking, for example, all the methods of std::set.
I just had an extensive look for something equivalent for modern versions of Visual Studio (currently I'm running 2019, probably will upgrade to 2022 soon), and I ended up only with web-based language guides for C++ from Microsoft.
Can anyone confirm if this documentation has been deprecated or if it is available in some form?
For rapid lookup of language features it was a very handy feature, one which I think could be very nicely brought back - it could show for example which modern C++ features are supported by which compilers. For me it would be awesome to have a well-structured and up-to-date language guide built into the IDE.
Thanks!

Usually, we get Language Reference in several ways:
Select the code (usually variables, functions and classes), then hit F1, you will jump to the corresponding document.
Select the code and press the right mouse button, you can select Peek definition to view the definition.
Search the code you need directly in MSDN.

Related

Poor intellisense in Visual Studio 2010 for C++ Win32

For a long time i was programming in Visual Studio 2010 in C#. Really good thing there was extensive documentation in Lntellisense. Lately i have decided to switch to C++ Win32 (which i believe is Native C++, am I right?). I have then spotted Intellisense is only showing functions' declarations (with no descriptions and with no parameter descriptions). It really makes programming hard as it is hard for me to remember all of the functions' parameters.
So the is: is there any way to make Intellisense to show documentation and parameter list descriptions for C++ win32 just like it was in C#?
If there is no such way, so is there way to provide my own XML documentation for existing win32 functions for C++? I could then write documentation for my most used functions for myself, which would be really helpful.
I have also noticed typing three slashes before function declaration does nothing (in C# it was used to write XML documentation for specified objecT). Is there any way to bring back such functionality?
You can try using Visual Assist X for better intellisense. It's a commercial tool (I'm not affiliated with them but I've been using it for a while). It provides features for most of the things you asked for through enhanced intellisense and macros / shortcuts.
For the most part I like it but there are some annoying issues with it that I had to learn to live with. Support is all right but every once in a while they break something that used to work before.

C++Builder XE2 or Visual Studio 11, from a VB application

Here where i work, we develop ERPs using Visual Basic 6 (Source Safe), MySQL and Crystal Reports 8.5, but the result isn't good as we expected.
We are planning to migrate from those tools, to C++Builder XE2 and Oracle, with github.
What reports application can we use? Anything better than Crystal Reports? C++Builder supports Oracle well?
With Visual Studio (C++ and Oracle), will i get better results?
Thanks
Both compilers and IDE's have different strength's and weaknesses. Try look at the answers in this post as well: C++ Builder or Visual Studio
I like a lot of things in C++ Builder (and for that matter Delphi, don't rule that one out if you consider C++ Builder). Basically if you need to do som GUI development and you insist on producing native windows applications, C++ Builder and Delphi has huge advantages. The VCL framework is really great, and closely tied with the IDE (which is ironically also its greatest weakness). There are obviously frameworks that provide some of the same functionality as C++ Builder, but I have yet to see one that works so well with the IDE.
The problem with this however, is that you really choose a platform, that is difficult to migrate away from. Not only does the VCL framework add some Embarcardero only language constructs (which are by the way often really nice ones if you are into that stuff). But the VCL framework is also proprietary, and an Embarcardero only product.
I have the last couple of years had some worries about the future of C++ Builder, it has started lacking behind the competitors in the interface, coding tools, and definitely the compiler which is far from the competitors.
Delphi however is a product that seems to receive much more attention from the developers, it has received a 64 bit compiler, (C++ Builder still lacks sigh). Delphi also produces native applications, works with Firemonkey so you can produce MacOS applications, and is less likey to be discontinued any time shortly (my personal guess). Besides there is a possibility to switch to the free Lazarus/Free Pascal IDE, although I have not stayed up to date on that for a while.
Basically what it boils down to is, what your requirements are. What do you need of the programming tools, for RAD development, given you need native code produced (you seem settled on C++), I would probably go for Delphi/C++ Builder. Yet I think you should try it first, and preferably give Qt/wxWidgets a shot as well to see if you can settle with that (Qt can prove to be expensive though), and perhaps get a solution that will be officially supported for a longer time.
If you find that your requirements are not as much based on the rapid aspects of the development, and you are searching for something that will give you as a coder a better toolbox for coding, and expect more of your compiler, I would not go for the Embarcardero products.
As for the database integration I cannot say much about Oracle for either of the two, but generally I find that C++ Builder/Delphi handles database connectivity and development using data aware controls, extremely well. It is really one of the key strengths of an RAD tool.
So try the two in some thought scenario as also jszpilewski mentions.
You may download the 30-days trial edition of C++Builder and check it yourself. It offers easy access to the Oracle Database (in Enterprise or Architect editions) and bundles with Nevrona Rave Reports. Hence it all should offer a similar workflow to VB6 in an environment that knows more about Vista and 7. One interesting advantage over Visual Studio would be cross-compilation for Mac if you can use the new Firemonkey framework instead of VCL.

Why would Microsoft still support nothrownew.obj?

According to MSDN, Microsoft still ships nothrownew.obj with the Visual C++ 10 (Visual Studio 2010) runtime library, so that users can link against it and have sub-standard behavior of "ordinary" (not nothrow flavor) new returning null on allocation failure. This sub-standard behavior dates back to Visual C++ 6 which is now considered extremely old.
Why would it do so? I mean they make each new version of the compiler more and more Standard-compliant. For example, Visual C++ 7 would support "default int", but Visual C++ 9 would not. And the old sub-standard behavior of new can be easily achieved by slightly changing code to use nothrow flavor of new - this is straightforward and very easy.
Why is this option so important that Microsoft still supports it?
Well, this is sort of an open question, since nobody except someone responsible from Microsoft can say for sure - if at all. So, I'll take a bite:
I'll guess it is for convenience:
Microsoft itself may need it in some of their products and it is just easier having it together with the compiler tools.
Microsoft may know that someone (say a big vendor/app) still needs it and it is just easier (or even necessary if compiler specific) to still provide it.
Microsoft may know/anticipate that it is generally still "widely" used in legacy apps. Big or small.
"It doesn't hurt", well arguably. For example, Microsoft has a long record of maintaining backward compatibility in Windows (see Raymond Chens blog), again, arguably not always for the better.
Documentation, Tests, etc. would need to be altered (or removed, but still).
That is, removing it may be more trouble yet then just keeping it.
At least they need / should provide a deprecated notice a version prior to removing it. I don't know if they did that for VS2010 or any prior version.
Because I am now (2012) porting a product from Visual C++ 6.0 to Visual Studio 2010 and that helps greatly to bring the development up to speed. We also will not make the Unicode transition for a few years to come. If Microsoft would not provide the compatibility feature I would build it myself.
As a side note we are a major ISV in a specialized field. If we decide to change OS, an entire Industry would probably change to. (Before Windows we used to also build a specialised OS.)

Collection of good C++ Themes in Visual Studio 2010?

I have found the site: http://studiostyl.es/ which specializes in Visual Studio 2010 themes. However, it appears that all of these themes are built with C# and .NET development in mind.
I am currently trying to get into some C++ programming and couldn't find anything on the subject of special themes for C++. Right now, almost all of my C++ code is a plain color and it looks like I might as well be writing it in notepad.
It may even be that I have my settings messed up and that those themes from studiostyles are supposed to be for all languages; I just started using Visual Studio.
Thanks for any replies.
No, the problem is that Visual Studio simply doesn't have anywhere near the built-in syntax highlighting support for C++ as it does for C# or VB.NET. Some syntax highlighting does work. For example, strings, comments, preprocessor directives, operators, numbers, and the built-in keywords all get their own colors. But a lot of your code will indeed be in one color ("Identifiers") if you don't lift a finger.
As Jerry suggests, Visual Assist X offers far better syntax highlighting than the default. But it's not free.
If you're like me and looking for a low-budget solution, you can define your own keywords. This will at least make them show up in the color earmarked for "User Keywords". The link explains what you'll need to do in more detail, but it's really as simple as placing a plain-text file named "usertype.dat" in the Visual Studio application folder, and typing each of the custom keywords that you want to appear highlighted in their own color on a separate line. You'll have to restart the IDE for your changes to take effect.
Since you're using VS 2010, another free solution is the Highlighterr for Visual C++ extension. This is one step up from defining your own keywords, and gets a little fancier with syntax highlighting. It takes advantage of the new Intellisense support in VS 2010 to turn on highlighting for classes, structs, macros, and typedefs. I haven't installed it yet myself because I'm still doing C++ development in VS 2008, but I'd very much like to try it out.
Get Visual Assist X and don't look back.
Edit: There is also Refactor! for C++. As you can guess from the name, it's oriented primarily toward refactoring code, but if memory serves can also do some colorizing and such. I haven't used it recently enough to say much more than that (I've used VA-X for years, and a couple of years ago decided to look at alternatives, but after a month or two of testing, decided to stick with VA-X).

Using Embarcadero Borland

As I'm more and more dissapointed with VS 2010 I'm trying to find some alternative and I was looking at Embarcadero's new edition of C++ env.
Is there any point of learning new (not popular I think) product when VS practically dominates market?
Thanks.
Although I'm not really a Windows programmer, I have been using Borland/Embarcadero to-and-fro during the past 10 years. Here are my personal opinions of why you should not consider it:
The general quality of Builder has dropped significantly over the years. Borland Builder 6 was the last high-quality product, from there the IDE itself has become more and more buggy. The IDE typically crashes once per 1-2 weeks of usage.
No undo in the RAD design. Yes I know, it is quite unbelievable. Even the earliest versions of utter crap like VB had this. But Builder year 2011 doesn't! If you slip on your keyboard and accidentally alter a component, you shall be punished!
The debugger is next to useless. This might have been fixed in the latest version, but in several versions you can't single step through the program without collapsing struct/class variables in the watch window, which is of course very frustrating.
Documentation is very poor, often non-existant, and may be written in Object Pascal, even though you ordered the C++ IDE. The help files also have a tendency to linger as evil ghost processes in your computer, making it impossible to shut down Windows before the ghost is busted.
Personally I'm considering switching to Visual Studio.
I've been using both the Embarcadero Borland, now RAD Studio 2010, c++ and VS2008 every day for the last 6 months. My programming philosophy has always been to use the right tool for the project, no matter what that particular tool is. So a couple of my observations/opinions are -
Advantages
The WYSIWYG screen designer is good. It acts a lot like the WinForms editor in VS2008, but for c++. In VS2008, the only package for c++ that I've used that is close is Qt. My biggest compliant is documentation, but that applies to most software, so it isn't just their problem.
For many builtin classes, they are built on TObject class. This base class functions a lot like Object in C#. The biggest advantage this gives you as a c++ programmer, if you follow a few rules, is mostly automatic memory management. It's not garbage collection, rather, list of related objects that are deleted together.
Disadvantages-
The RAD Studio 2010 C++ environment exists primarily to support Delphi. That is their real strength anyway. Nowhere does anything say this. It is just an overall feel that I've gotten from using system.
Limited support for 3rd party libraries.
It cannot link with any Microsoft compatible c++ library. This includes both Microsoft and 3rd party libraries. They use a different "name mangling" format from Microsoft. So everything has to wrapped in a c language wrapper.
We use the Boost Libraries a lot in VS2008. But in Rad Studio, it only has limited support for Boost.
I've found the overall speed of the generated code to significantly slower than that produced by VS2008.
Please remember, that these are just one person's opinions.
I would suggest that you download a demo version of the product and try it for yourself.
If you want to be 100% up-to-date, you have to use the development environment provided by the platform's vendor.
If you do not mind waiting few months/years for new things to get ported over (or your market allows for it) then you surely you can venture into the unknown.
It's not that Borland's IDEs (unlike MS' VS family) needed any advanced training to start using them and be already productive. That is the main reason why they remain popular in many niches.