This topic is now archived and is closed to further replies.

How compliant is Visual Studio .NET?

This topic is 5977 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Has anyone here beta tested the new Visual Studio .NET? I''m curious as to how much better it is than VS6''s oh-so-wonderful STL and general template support...does it actually at least pretend to comply with the standards? Thanks, Anthracks

Share this post

Link to post
Share on other sites
I have the cd''s but haven''t installed them. guess I should try it out.

Never underestimante the power of stupid people in large groups.

Share this post

Link to post
Share on other sites
I can''t seem to find the article, but the short answer is no it does not. What the article said is that they were too busy making VC++ works with .net that they did not had the time to fix all the standard issues mainly partial template specialization(which is needed for full standard stl support).

They said maybe next version of .net. That would be in 2 years I guess!

Share this post

Link to post
Share on other sites
Martee, you''re implying that Microsoft invented XML, which they did not. XML was developed "by an XML Working Group (originally known as the SGML Editorial Review Board) formed under the auspices of the World Wide Web Consortium (W3C) in 1996. It was chaired by Jon Bosak of Sun Microsystems with the active participation of an XML Special Interest Group (previously known as the SGML Working Group) also organized by the W3C." (

Share this post

Link to post
Share on other sites
Nononono. You misunderstood me.
I was referring to the ".NET is all proprietary Microsoft stuff - who needs standars?" idea. I know that MS didn''t invent XML. They also didn''t invent SOAP (although they were major contributors to its development). My point was, .NET relies heavily on standards, many of which were not developed by Microsoft.


Share this post

Link to post
Share on other sites
Guest Anonymous Poster
I''ve been playing around with VS.NET Beta 2 for a couple of days. Here''s some code I threw together to test out VS.NET''s standards compliance. None of this stuff works in VC6, all of it works in VC7.

#include <list>
#include <vector>
#include <string>
#include <iostream>
#include <algorithm>

// dim_of returns the dimensions of an array. This is better than

// the typical #define DIM_OF(arr) (sizeof(arr)/sizeof(arr[0]))
// for a variety of reasons, but specifically, it prevents pointers

// from accidently being passed.

template <typename T, std::size_t N>
inline std::size_t dim_of(T (&)[N]) { return N; }

#define DIM_OF(arr) (sizeof(arr)/sizeof(arr[0]))

// A::Clone() differs from B::Clone() only by return type, but

// since B is derived from A, the standard allows this.

struct A {
virtual A* Clone() const = 0;

struct B : A {
virtual B* Clone() const = 0;

// A simple tester for later (note that Go''s return type is void)

class Whatever { public: void Go() {} };

int main()
// Convert ANSI string to Unicode

std::string str = "Hello";
std::wstring wstr(str.begin(), str.end());

// Play around with all sorts of new things

int myArr[5] = { 1, 2, 3, 4, 5 };
std::list<int> myList(&myArr[0], &myArr[0] + dim_of(myArr));
std::vector<int> myVect(myList.begin(), myList.end());

// Test out dim_of vs. DIM_OF

//dim_of(str.c_str()); // GOOD: This won''t compile.

DIM_OF(str.c_str()); // BAD: This does compile.

// Test mem_fun with a function returning void. The standard allows for

// void functions to return "values" in certain case in order to make

// template writing easier.

std::list<Whatever*> wList;
std::for_each(wList.begin(), wList.end(), std::mem_fun(&Whatever::Go));

//return 0; // "return 0" from main isn''t necessary in C++ anymore


Share this post

Link to post
Share on other sites

I am glad that the initialising of 1 container type from another is working in the new VC++. Although, this was not a MSVC problem as such, it''s because they use an old STL in VC6 which isn''t very generic as far as iterators go, sadly. Although VC5 couldn''t compile templatized member functions, VC6 can, it just doesn''t take advantage of this since it still has VC5''s STL.

Share this post

Link to post
Share on other sites