On 2/15/07, Ion GaztaƱaga wrote:
Hello everyone,
The review of the proposed Boost Bimap library written by Matias
Capeletto starts today (February 15th, 2007) and ends after 10 days
(February 25, 2007).
So far:
A: namespace:
---------------------
from the 'One Minute Tutorial':
That is more or less all that is needed to start using the
bidirectional map. The following two lines must also be added:
#include
using namespace bimap;
2 points:
- I prefer not to use 'using'. I know I don't have to, but I don't
like that the docs imply that I do.
more importantly:
- is it going to be in 'bimap' or in 'boost'?
B: 'relation'
----------------
I think I understand the philosophical reasoning for preferring
'left/right' over 'first/second', and thus the impetuous for creating
'relation'. However...
- I think 'relation' is too generic a word to abscond.
- how about:
- couple
- duo
- or probably just 'bipair'
- or maybe even consider that std::pair, although not perfect, might
make things easier:
- it can be used in other algorithms
- it is already well known
- the nature of typing code forces order - ie note that bimap
is different than bimap (although philosophically the same).
Even with 'left/right' you still have order - left corresponds to the
*first* type listed in the bimap, 'right' corresponds to the *second*
type passed in. Or is it bimap? I don't think so.
But other than that, so far so good. Looks like something I'd use.
And the docs are snazzy.
- Tony