[PATCH] unsigned count() for ADT

Yaron Keren yaron.keren at gmail.com
Tue Jun 10 06:31:52 PDT 2014


>From the list discussion, Richard Smith:

If we want our container-like types to be containers, count should return size_type. I suspect that size_type == size_t is probably the best choice (for performance and code size), but I really doubt this makes much difference. I don't think there are many cases where we'd want to support containers of more than 4Gi elements. (In short, I don't think this really matters, but each container should be internally consistent.)

http://reviews.llvm.org/D4018






More information about the llvm-commits mailing list