Visual C++ Development Chief Highlights Key New Features in Version 6.0

MSDN Interview
June 1998

MSDN tracked down Sin Lew, development manager and architect of the new Visual C++® version 6.0, to ask him what's coming in the new version of Microsoft's premier tool for professional developers. From totally new features such as "Edit and Continue" debugging to familiar IntelliSense® technologies now debuting in Visual C++, Lew outlined what developers can expect to find in Visual C++ 6.0. Here is the transcript of his interview with MSDN Online's John Swenson.

MSDN: We're here with Sin Lew, who led the development of Microsoft's new Visual C++ 6.0. Let's start with a broad question. Briefly, can you summarize the most significant new features that you think developers will want to hear about in Visual C++ 6.0?

Lew: Visual C++ 6.0 has a number of major features, from enhancements in MFC for new UI design and Web integration to new ATL wizards and ATL controls. But the most significant new features of Visual C++ probably are "Edit and Continue" debugging and IntelliSense.

Edit and Continue debugging is a means by which you can modify your code and fix your bug in the debugger itself. Then you can continue without having to stop, recompile, rebuild, and come back to the state in which your application was running at that time.

IntelliSense is a technology by which you have the information right when you need it—that's the important thing. It gives you the information when you're typing, when you're working on a method of a class or an interface. It tells you what the method does, its comments if there are any, and even what parameters the method takes. Having that information right there helps you continue your flow of work without having to stop and do anything different.

MSDN: Microsoft has spent a lot of time adding IntelliSense features to all its products, from Office 97 to Visual Basic. Is the new IntelliSense in Visual C++ like the IntelliSense in Visual Basic, where you get a drop-down box while you're writing code?

Lew: Yes. IntelliSense in Visual C++ is very similar to IntelliSense in Visual Basic. However, Visual C++ requires a much richer set of information for the entire Win32 API, MFC, ATL, etc. You can have classes, interfaces, methods, and the inheritance tree. The Intellisense in Visual C++ needed to be much more robust and much more sophisticated to provide you that information right at your fingertips.

MSDN: What are some other ways that Visual C++ 6.0 will make developers more productive?

Lew: One of the goals of Visual C++ 6.0 is to make developers very productive by having a number of features such as wizards for building different types of COM objects, ActiveX controls, OLE DB providers, etc.—even Microsoft Cluster Server resource types. We wanted to make sure our wizards help the developer get rid of all these sundry tasks, so the developer can concentrate on solving his or her problems.

With IntelliSense, information is provided right when you need it, in a very nonintrusive way. It tells you exactly what you need to put in as parameters or method names.

We also improved our compile time and build times, so you don't have to spend much time building your application. You can spend more of your time actually developing your application. For example, when we compiled NT 4.0 with the new 6.0 toolset, it compiled 30 percent faster. That's a significant savings.

We also added improvements such as "Edit and Continue" in the debugger. You don't have to stop in the debugger and recompile your code. You can just modify your code in the debugger itself and continue on, without having to go back and do any of those rebuild steps.

MSDN: So this is really a major release, with a lot of improvements.

Lew: Yes. This is a major release with a lot of productivity features, great Internet and distributed computing features, and a lot of features for the system itself.

MSDN: If developers are used to Visual C++ 5.0, will they find it easy to move to Visual C++ 6.0?

Lew: Absolutely. Visual C++ 6.0 is a superset of Visual C++ 5.0. Developers should get Visual C++ 6.0 and recompile their code, because they'll find a number of improvements throughout the whole product, not only in developing applications, but also in terms of new features for their applications.

MSDN: What will Microsoft's new Visual Studio 6.0 tools suite offer Visual C++ developers that they can't get from using Visual C++ 6.0 by itself?

Lew: Visual Studio adds some new features, such as allowing developers to find out where their application is spending a lot of time. With the Visual Studio Analyzer, developers are able to figure out where their application is spending time. They can rewrite their application in C++ if it is written in a different language, or even fine-tune that particular component to get better performance and scalability.

But the most important part of Visual Studio is the collection of tools provided in Visual Studio 6.0: Visual C++ of course, and Visual Basic, Visual InterDev, Visual FoxPro, and Visual J++. A lot of Visual C++ developers use a multitude of languages in order to develop their applications. Approximately 60 percent also use Visual Basic. Having a complete tool set is very important for developers.

There are some great new enterprise features in Visual C++ 6.0 Enterprise Edition that you can also get in Visual Studio Enterprise Edition. For example, the integrated Visual Database Tool lets developers get to Oracle databases just like they've been able to do with SQL Server, and do things like modify schemas. And the Visual Component Manager not only gives developers a great mechanism for reusing components across development teams, it also lets them work with SAP's Business Objects, which are now all COM objects.

MSDN: Every Microsoft tool is gaining more support for Web development. I assume Visual C++ 6.0 is too. Can you explain these new Web development capabilities?

Lew: Since the Internet became a big thing, the Visual C++ team has focused a tremendous amount of energy into trying to support the Internet. With Visual C++ 5.0, we added support for ISAPI, the server API in MFC. On the client side, we supported WinInet.

In Visual C++ 6.0, we want to allow our developers to take their MFC applications to the Web and vice versa. So we added a new class called CHtmlView, which hosts Dynamic HTML. This allows you to render HTML in your MFC applications, so you can customize your application for the Web.

We've also done a lot of things with components. We've added a Dynamic HTML control in ATL, so you can build controls that host Dynamic HTML to render HTML. But most importantly, when you build applications for the Internet, you're talking about size and efficiency.

In Visual C++ 6.0 you can build components with ATL that are very small. ActiveX controls are very small in ATL and very fast. Web pages can be very rich. A rich page usually contains a number of controls. Visual C++ 6.0 allows you to build very small, efficient controls and improve them easily with our Wizard technology.

MSDN: Let's drill on to some specific features and technologies in Visual C++ 6.0. What changes does Visual C++ 6.0 make to MFC?

Lew: We made a number of changes to MFC. Visual C++ 6.0 has a new version of MFC that is binary compatible. We have added support for the new common controls in Internet Explorer 4.0. We also added support for hosting Dynamic HTML through the CHtmlView class. We've also made some performance improvements in MFC. If you statically link a MFC library to your application, you get a much smaller size and better startup times. So, we've done significant improvements to MFC to support the new system.

MSDN: What about ATL? Does Visual C++ 6.0 make changes there, too?

Lew: Yes. We have a new version of ATL in Visual C++ 6.0, ATL version 3.0. We've made it more scalable for multiprocessor machines, through memory allocation enhancements. We also added a number of wizards to ATL. These allow you to support, for example, the new Dynamic HTML control and MMC—Microsoft Management Console snap-ins. There are also OLE DB consumer and provider templates in ATL. These are a very efficient yet rich mechanism for data access.

MSDN: What will Visual C++ 6.0 do to help developers who are using both MFC and ATL in the same project?

Lew: This is where I think we have heard our customers loud and clear. Today, in order for MFC applications to use ATL, developers have to do a little bit of coding in order to glue them together. With Visual C++ 6.0, you can actually insert an ATL object into an MFC project, using the ATL object wizard.

We think a lot of developers will like this feature, because a lot of developers want to use both MFC and ATL in their applications. Sometimes they want to use MFC when adding functionality in ATL. We've made that very easy in Visual C++ 6.0.

MSDN: Is it hard to use ATL and MFC together in the same project today?

Lew: Yes, it is hard to use ATL and MFC together today. It takes a little bit of work. With Visual C++ 6.0, we make this easy with a new wizard.

MSDN: COM was a key topic at Microsoft Tech·Ed 98 and the Visual C++ Developer's Conference. What new features in Visual C++ 6.0 will help VC developers create COM components?

Lew: COM has been one of our major focuses in every Visual C++ release. In Visual C++ 6.0, we've added new wizards to help you build different kinds of components, such as the Dynamic HTML component, OLE DB templates, and consumer and provider templates. We've also improved the performance of our ATL controls for multiprocessor machines, providing much better scalability.

We've also provided light controls in ATL. This is because we think people will want small controls for the Internet. Size is a very important factor here, and these light controls are very useful.

We also found out that people want to build composite controls. These allow you to build controls that are hosted inside other controls, thus providing a much richer set of controls to other applications. We provide a very simple, very graphical mechanism for doing that.

MSDN: How does Visual C++ 6.0 improve data access for developers?

Lew: This is another big focus of ours. In Visual C++ 6.0, we provide OLE DB consumer and provider templates that have wizards to help you to build the infrastructure for accessing data through OLE DB.

OLE DB is a COM-based data-access technology. It's a very efficient mechanism of accessing your data, yet also very flexible. It is flexible because you can write an OLE DB provider on top of any kind of data you have, whether it's your custom data format, a database, or just a simple file. We provide you the mechanism to build an OLE DB provider on top of that, and then build an OLE DB consumer to access that data. If you happen to want a little higher abstraction layer, we support ADO, too.

MSDN: I understand there are some simplified OLE DB templates in VC 6.0 that reduce the amount of code developers must write. Can you explain these?

Lew: The OLE DB templates in Visual C++ 6.0 provide the whole infrastructure for building providers or consumers for data access. For example, if you were to write your own OLE DB consumer directly to the interfaces, you would have to do all the bindings yourself and generate a lot of code in order to be able to walk through the records.

With the new wizards in Visual C++ 6.0, a lot of that is taken care for you. We provide you the default implementation for binding the data itself. You can go in, add your few statements in order to bind to the columns, and you're done. You can have methods to move through the records, modify records, and things like that. The model is very similar to MFC's data-access technology—a very simple, quick means of getting to your data, yet efficient.

MSDN: What is ENC and how will it benefit Visual C++ developers?

Lew: ENC stands for Edit and Continue debugging. It's something I think a lot of developers will love. ENC adds the capability of being able to fix your bug right when you find it, and then continue running to see if your fix is correct.

ENC is very important for developers because when you write large or mission-critical applications and you're debugging them, it may take a couple of hours before your bug surfaces. You don't want to have to go back and rebuild and then re-reach that state before you can check out whether your fix is right. With edit and continue in the debugger, you can do that immediately, as soon as you see it.

MSDN: There's nothing like that in Visual C++ 5.0.

Lew: No, there isn't.

MSDN: What are some of the performance improvements in Visual 6.0? Can you comment more on specific improvements to the compiler?

Lew: There are a number of improvements in Visual C++ 6.0 that we did for performance. One is support for delay loading imports. This feature in the linker no longer forces you to load all your DLLs at the beginning, when your application starts up. Your application can start up immediately, as fast as it can, without having to require loading all these pages into memory right away. You can load it when you really need it, so you're getting a lot of performance improvement off that.

We've also made performance improvements to the compiler through incremental improvements for optimizations. In Visual C++ 5.0, we improved our optimizations dramatically, and in Visual C++ 6.0, we improved them again.

We also improved compiler throughput. We're seeing a 20 to 30 percent improvement in compile times through our new compiler. Beyond the compiler, we've also made performance improvements in MFC. Because MFC is statically linked, it makes the code smaller and brings exactly what your application needs. Startup times are better, and your application runs faster, too.

MSDN: What were some of the hardest features your team worked on to add to Visual C++ 6.0?

Lew: All the features in Visual C++, in 6.0 were very challenging, but I would say Edit and Continue and IntelliSense were the most challenging. Edit and Continue was challenging because we wanted to do it on native code. We wanted to do it on the .exes that people build, and not have to build an intermediate tree mechanism to run the .exe.

That required us to build a whole new infrastructure. We also had to make it as fast as possible so that the lapse time from when you modify your code and it is rebuilt and starts executing is extremely small.

IntelliSense required another infrastructure change. We needed to compile your code behind the scenes, and it had to be completely nonintrusive. It had to collect all that data and access that data extremely fast. That was another challenge, but we made it. We did it.

MSDN: Let's shift the focus from new features to developers and customers. How are customers you've talked with using the beta of Visual C++ 6.0?

Lew: A number of companies are using the Visual C++ 6.0 beta in incredible ways. A lot of companies, such as the SAS Institute, are building OLE DB providers for unstructured data stores. And companies like Kaiser Permanente are building great multi-tier applications that run on both NT and UNIX. Others, such as Barclays and NASDAQ, are using it to enhance their Web servers with ATL and MFC.

Microsoft is using it with Sidewalk.com. Sidewalk uses Visual C++ to build all its components, the whole Web server, things like that. The beta is being used in lots of different ways. All of our common controls are very well received. Edit and Continue is a feature no one expected, but is turning out to be such a boon to everyone. And IntelliSense—having that information right when you need—that's something people have just raved about.

MSDN: How soon can developers get Visual C++ 6.0? Is there any way they can get the beta before September, or are you making people wait until the product is out?

Lew: The beta program is closed now, but we are working towards release. It won't be long before Visual C++ 6.0 is available. [Editor's Note: Visual C++ 6.0 is due out in early September.]

MSDN: Any final words of advice for Visual C++ developers moving to version 6.0?

Lew: All developers should go out and get Visual C++ 6.0 and recompile their code with it. They'll find it will make their projects build quicker, produce faster code, and make them much more productive as developers, thanks to all the features I talked about. Visual C++ 6.0 can also make their applications richer, due to all the new MFC and ATL enhancements in the product.