ZRainy
ZRainy

Reputation: 13

What does the call operator STL USES here mean?

I was recently looking at the source code for SGI STL and found many places where it used call operators that I could not understand, such as:

typedef typename _type_traits<T1>::is_POD_type is_POD;
_uninitialized_fill_aux(first, last, v, is_POD());

There is a call operation at the end(is_POD()).

I know is_POD is a type and it is defined as follows:

struct _true_type{};
struct _false_type{}; 

template <class T>
struct _type_traits{ 
    ...
    ...
    typedef _false_type is_POD_type;
};  

As I see, is_POD is a type but it does not overloaded the () operation, so how can it call ()

What does the call funtion at this place mean?

Thank you very much!

Upvotes: 0

Views: 55

Answers (0)

Related Questions