Boost logo

Boost :

Subject: Re: [boost] Formal Review Request: TypeErasure (docs, Concept Maps misnamed?)
From: Larry Evans (cppljevans_at_[hidden])
Date: 2012-06-23 11:55:54

On 06/21/12 21:38, Steven Watanabe wrote:
> On 06/21/2012 04:49 PM, lcaminiti wrote:
>> I read the docs and didn't find the concept naming confusing (on the
>> contrary, it's "standard" terminology). However, I agree that a Wiki
link to
>> concepts would be useful from in the docs as not all readers will be
>> familiar with the C++0x concept proposals:
> The only use of "Concept Map" is the title
> of the section. I believe that the contents
> of the section make it sufficiently clear
> what I'm talking about.
The contents say:

  Sometimes it is useful to non-intrusively adapt a type to model a
  concept. For example, suppose that we want to make std::type_info
  model less_than_comparable. To do this, we simply specialize the
  concept definition.

which is clear, especially the part:

  specialize the concept definition.

However what is not clear is how the title, "Concept Map", is related
to what's in the content. That's what prompted my original post in
this sub-thread:

Your response:

  b) "Concept Map" is the concept term for

shown here:

prompted me to google for "C++ Concept Map" which lead to here:

and only after reading that was the rationale for the title clear.

(However, after thinking some more, it seems a combination of the
concept definition *and* the concept_interface corresponds to the
"Concept Map" shown in the wikipedia article. That's because the
concept definition has no member functions (such as operator+ or
push_back) defined in it. The concept definition, AFAICT, only
needs to supply a static member function called apply.


The member functions are added by concept_interface.


Only after the member functions are added by the concept_interface is
an entry for the concept map complete. I guess, here, the map is from
a type, T, to an any type like T but with the added member functions
added by the combination of the concept definition and the
concept_interface. Is that about right?

In summary, as you say, the content is clear, but the rationale for
the title is not, unless a link to something like the wikipedia
article is provided.



Boost list run by bdawes at, gregod at, cpdaniel at, john at