Created on 2011-02-07.00:00:00 last changed 167 months ago
[ 2011-02-25 Reflector discussion ]
Moved to Tentatively NAD after 5 votes.
[ 2011-02-24 Chris Jefferson adds: ]
I recommend NAD, due to [contents] p3:
Whenever a name x defined in the standard library is mentioned, the name x is assumed to be fully qualified as ::std::x, unless explicitly described otherwise. For example, if the Effects section for library function F is described as calling library function G, the function ::std::G is meant.
[ 2011-02-07 Howard Hinnant adds: ]
I think this is incorrect. We mean std::hash, though clients are free to specialize std::hash on user-defined types. With the possible exception of begin/end (which I'm not sure if we've settled that), swap is the only intended customization point (look up a function by ADL) in the std:: lib.
[ 2011-02-07 Chris Jefferson adds: ]
I assumed (I might be wrong) it is because hash is designed to be a customisation point, like swap.
Tom Plum pointed out to me that there's an apparent inconsistency in the std:: qualification of template names in the unordered containers:
template <class Key, class T, class Hash = hash<Key>, class Pred = std::equal_to<Key>, class Alloc = std::allocator<std::pair<const Key, T> > > class unordered_map;
Is there a reason that hash is not qualified with std::? TR1 also does not use std:: here.
History | |||
---|---|---|---|
Date | User | Action | Args |
2011-02-25 16:08:15 | admin | set | messages: + msg5548 |
2011-02-25 16:08:15 | admin | set | status: new -> nad |
2011-02-24 22:27:25 | admin | set | messages: + msg5542 |
2011-02-07 14:20:34 | admin | set | messages: + msg5477 |
2011-02-07 14:20:34 | admin | set | messages: + msg5476 |
2011-02-07 00:00:00 | admin | create |