I have a structure whose objects are to be pushed into the boost::heap::priority_queue.
typedef struct
{
  int i, j;
  double deltaQ;
} heapNode;
int main()
{
    double a[] = {0.03, 0.01, 0.04, 0.02, 0.05};
    heapNode node;
    boost::heap::priority_queue<heapNode> maxHeap;
    for(int  i = 0; i < 5; i++)
    {
        node.deltaQ = a[i];
        node.i = i;
        node.j = i;
        maxHeap.push(node);//error
    }
    for(int i = 0; i < 5; i++)
    {
        node = maxHeap.top();
        cout << node.deltaQ << " " << node.i << " " << node.j;
        cout << "\n";
        maxHeap.pop();
    }
}
this code gives a compiler error that,
error: no match for 'operator<' (operand types are 'const heapNode' and 'const heapNode')|
Any solutions to this, I'm usinf codeBlocks 16.01.
Thanks
 
     
    