Indiana Unversity logo[ConceptGCC]

ConceptGCC :

Re: Signatures for Static Member Functions

From: Doug Gregor (dgregor_at_[hidden])
Date: 2006-07-25 15:41:06


On Jul 25, 2006, at 10:31 AM, Bonderer Rolf wrote:

> Hi Doug,
>
> There's one more problem I encountered when working with ConceptC+
> +. Is there actually a way of defining static member functions? I
> would like to use something like:
>
> concept Norm <typename N, typename Vector, ...>
> {
> typename result_type_norm;
> static result_type_norm N::operator()(Vector);
> ...
> };

operator() won't be able to be a static function requirement, because
C++ does not support static function-call operators. ConceptC++ does
allow static members, e.g.,

concept Graph<typename G>
{
   typename vertex_type;
   static vertex_type G::null_vertex();
}

Unfortunately, I haven't implemented this functionality in ConceptGCC
yet :(

If it's critical, I can try to take a whack at it within the next week.

        Doug