Boost logo

Boost :

From: David Bergman (davidb_at_[hidden])
Date: 2004-02-12 14:39:44


David Abrahams wrote:

> "David Bergman" <davidb_at_[hidden]> writes:
>
> > David Abrahams wrote:
> >
> >> Angus Leeming <angus.leeming_at_[hidden]> writes:
> >>
> >> > David Abrahams wrote:
> >> >>> In the section "Template Arguments for iterator_facade" is the
> >> >>> subsection "CategoryOrTraversal". I suspect that should be
> >> >>> "CategoryOfTraversal" (s/Or/Of/).
> >> >>>
> >> >>> The iterator_adapter docs spell it "CategoryOrTraversal" too.
> >> >>
> >> >> No, the spelling is as intended.
> >
> > The naming of the implementation, and the (informal, so
> far?) proposal
> > by you, Siek and Witt (sp?), is a bit misleading.
>
> Well, it seems as though you were misled somewhere along the way.

Ok, let us see.
 
> > A few comments/suggestions:
> >
> > 1. A group of concepts should be called either "group" or "category"
> > (I think you stick to the former most, of not all, of the time)
> > consistently in both proposal and implementation.
>
> I have no idea what you're referring to. Maybe you should
> specifically point to text you think should be changed, and why.

I think you have an idea of what I am talking: the proper name to use for
the concept groups.

You want to stick to "group" because the Standard uses that name. Fine,
makes sense. I have seen "category" being used for that notion.
 
> > 2. Why is one concept group (i.e., one part of the
> dichotomy) called
> > "category"
>
> Because that's what the existing standard calls it.

The existing standard does not even split the Iterator group into two
dimensions, so how can they call that not-yet-invented dimension anything?

They use "category tags" for tags to groups, and subgroups, of concepts.
I.e., their use has nothing to do with the "access" dimension. Additionally,
does not "category tags" for tagging groups of concepts somehow imply that
the word "category" for concept groups is not all that far far-fetched.

> > and the other "traversal."
>
> Because that's what it describes.

Fine.
 
> > Potential confusion ahead... I propose "access" and "traversal,"
>
> Existing category tags do not describe just access. They
> describe a combination of access and traversal, as you can
> see by reading
> http://www.boost.org/libs/iterator/doc/new-iter-concepts.html

Category tags is one thing, the "access" dimension another. This is where
the possible confusion might arise:

a. groups of concepts - called "groups"

b. the tag used to label a group, or subgroup, of concepts - called
"category tag"

c. the access group of concepts pertaining to iterators - called "category"?

> > since I see no more of a "categorically" intrinsic property in one
> > group than the other, i.e., labeling the access dimension as
> > categorical is a bit unfair to the poor traversal dimension ;-)
>
> It would be, but we're not doing that.

So, what are you calling that other, orthogonal group, if not "category"?
 
> > Furthermore, connected to (1), category is often used to denote a
> > group of concepts, so I understand Angus' confusion.
>
> I don't know what you're talking about again.

You do not know that the word "category" is often used to denote a group of
concepts in generic programming? As in "category tags."

> > 3. In the traversal group/category of concepts, they should either
> > *all* include the lexeme "traversal" or *none*.
>
> Probably a good idea. We made that change to the tags, but
> not to the concept names.

Ok.
 
> > In fact, I propose to completely skip the "traversal" in
> the concept
> > names. The only potential conceptual hurdle is the "access" in
> > "random_access" (or RandomAccessIterator) that can be confused with
> > the access-related group of concepts...
>
> Bad idea, IMO. incrementable_tag, for example, shouldn't be
> reserved by an iterators library; it could apply to lots of things.

I agree with that cross-group applicability of the tag, but what has that
insight to do with skipping "traversal" in the concept names?

> > 4. The access group of iterator concepts: what is so "iterative"
> > about them? I.e., are they not general proxy concepts,
> with potential
> > applications in smart pointers and other proxy situations?
>
> ...and your point is...?

Exactly the point you made in your last comment, namely, that "it could
apply to lots of things."
 
> They were designed so that they could be used independently
> from traversal.

That was the point I was making...

/David


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk