
On Tue, Oct 2, 2012 at 12:35 AM, Sebastian Redl <sebastian.redl@getdesigned.at> wrote:
On 02.10.2012 09:26, Andrzej Krzemienski wrote:
BTW, why do we declare concepts like:
concept EqualityComparable< typename T > = ... // (1)
Instead of:
template< typename T > concept EqualityComparable = ... // (2)
A concept isn't a template.
Of course.
You don't instantiate a concept template to get specialized concepts.
However, syntactically you use it similarly to a template: MyConcept<T1, T2, T3> my_template<T1, T2, T3>
There is just the concept, which has type parameters.
This would be more obvious if we wrote it thus:
concept <typename T> EqualityComparable = ... // (3)
Actually, this would make the most sense to me, why wouldn't we use this syntax (3)? Thanks, --Lorenzo