Jump to content
  • Advertisement
Sign in to follow this  
Darkneon

[.net] STL in C#?

This topic is 4849 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

Hi guys, Is there in C# something as the STL in C++? How would I use vectors, lists and queues? Thanks Darkneon

Share this post


Link to post
Share on other sites
Advertisement
C# has its own types, I cant remember the exact names since it have been a while since I programmed C#, but I remember it had much more of these kind of types than C++ have.

Share this post


Link to post
Share on other sites
In C# you have two choices. You can use untyped collections such as ArrayList or HashTable that hold Objects (from System.Collections), or if you have access to .NET 2.0 (such as via the MS visual studio 2005 betas) you can use the generics versions such as List<> or SortedDictionary><> in System.Collections.Generic.

Share this post


Link to post
Share on other sites
The Best Thing Ever(tm) is that the Visual Studio debugger can actually make sense of the contents of the System.Collections.Generic collection types. I haven't ever gotten C++ std::map to make any sense in a debugger.

Share this post


Link to post
Share on other sites
Quote:
Original post by Nypyren
The Best Thing Ever(tm) is that the Visual Studio debugger can actually make sense of the contents of the System.Collections.Generic collection types. I haven't ever gotten C++ std::map to make any sense in a debugger.
STLFilt.

Share this post


Link to post
Share on other sites
Quote:
Original post by Oluseyi
Quote:
Original post by Nypyren
The Best Thing Ever(tm) is that the Visual Studio debugger can actually make sense of the contents of the System.Collections.Generic collection types. I haven't ever gotten C++ std::map to make any sense in a debugger.
STLFilt.

That doesn't in any way solve his problem.

Share this post


Link to post
Share on other sites
Quote:
Original post by Oluseyi
Quote:
Original post by Nypyren
The Best Thing Ever(tm) is that the Visual Studio debugger can actually make sense of the contents of the System.Collections.Generic collection types. I haven't ever gotten C++ std::map to make any sense in a debugger.
STLFilt.


What he's saying is that the debugger will happily show you the contents of the collections (even if they aren't generic). In the Express version, it comes up as a tooltip(!).

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!