error: no matching function for call to ‘BSTreeNode<int, int>::BSTreeNode(int, int, NULL, NULL)’ - what's wrong?
- by Alexander Suraphel
error: no matching function for call
to ‘BSTreeNode::BSTreeNode(int, int, NULL,
NULL)’
candidates are: BSTreeNode::BSTreeNode(KF, DT&,
BSTreeNode*, BSTreeNode*) [with KF = int, DT = int]
here is how I used it:
BSTreeNode<int, int> newNode(5,9, NULL, NULL) ;
I defined it as follows:
BSTreeNode(KF sKey, DT &data, BSTreeNode *lt, BSTreeNode *rt):key(sKey),dataItem(data), left(lt), right(rt){}
what's wrong with using my constructor this way?
i've been pulling out my hair all night please help me ASAP!!