Archived

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

__fold

Simple question about vectors

Recommended Posts

My reference says that functions like at() and resize() takes a parameter of type size_type. How do I know what size_type is for my compiler and will it be different if I use other compilers?

Share this post


Link to post
Share on other sites
quote:
Original post by xg0blin
size_t is defined in stdlib.h I believe, so just look in the file.

He is reffering to size_type which is defined in the std::vector container.

Fold, to answer your question, size_type is defined as a type that can hold any value smaller than the maximum size that a vector container can be for the specific type of objects that it is to hold. Did that make sense? Perhaps someone can explain this better...

[edited by - chacha on October 22, 2003 10:54:39 AM]

Share this post


Link to post
Share on other sites