Error: Char 9: error: type 'mypq_type' (aka 'priority_queue<int, vector<int>, function<bool (int, int)> >') does not provide a call operator
pq (comparator);
As you see I need to pass a custom comparator function for the priority queue pq which is a data member for a class.
to call the constructor of base class and member variables use the initializer list
1 2 3 4 5 6 7
Node(function<bool(int,int)> comparator): //colon
//here you call the constructors
pq(comparator)
{
//here all your members are already constructed, and you may operate on them
pq.push(42);
}