Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Complier Error #1

Open
zterefe opened this issue May 15, 2019 · 0 comments
Open

Complier Error #1

zterefe opened this issue May 15, 2019 · 0 comments

Comments

@zterefe
Copy link

zterefe commented May 15, 2019

main.cpp:411:29: error: no matching constructor for
initialization of 'usefulData'
usefulData s1 = insert(root, d, p);
^ ~~~~~~~~~~~~~~~~~~
main.cpp:1110:19: note: in instantiation of member function
'two3Tree::insert' requested here
tree1.insert(data);
^
main.cpp:25:5: note: candidate constructor not viable: no
known conversion from 'usefulData' to
'two3node ' for 1st argument
usefulData (two3node
c)
^
main.cpp:47:5: note: candidate constructor not viable:
expects an l-value for 1st argument
usefulData(usefulData & otherusefulData)
^
main.cpp:30:5: note: candidate constructor not viable:
requires 2 arguments, but 1 was provided
usefulData (two3node* c, T m)
^
main.cpp:452:15: error: no viable constructor returning
object of type 'usefulData'
return (NULL);
^ ~~~~~~
main.cpp:411:34: note: in instantiation of member function
'two3Tree::insert' requested here
usefulData s1 = insert(root, d, p);
^
main.cpp:1110:19: note: in instantiation of member function
'two3Tree::insert' requested here
tree1.insert(data);
^
main.cpp:25:5: note: candidate constructor not viable: no
known conversion from 'usefulData' to
'two3node ' for 1st argument
usefulData (two3node
c)
^
main.cpp:47:5: note: candidate constructor not viable:
expects an l-value for 1st argument
usefulData(usefulData & otherusefulData)
^
main.cpp:30:5: note: candidate constructor not viable:
requires 2 arguments, but 1 was provided
usefulData (two3node* c, T m)
^
main.cpp:766:34: error: no viable overloaded '='
...s1 = Delete (r -> left, d, r);
~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~
main.cpp:741:11: note: in instantiation of member function
'two3Tree::Delete' requested here
Delete(root,d,p);
^
main.cpp:1121:19: note: in instantiation of member function
'two3Tree::deleteNode' requested here
tree1.deleteNode(data);
^
main.cpp:36:19: note: candidate function not viable:
expects an l-value for 1st argument
usefulData operator = (usefulData & other...
^
main.cpp:809:23: error: no viable constructor returning
object of type 'usefulData'
return (NULL);
^ ~~~~~~
main.cpp:25:5: note: candidate constructor not viable: no
known conversion from 'usefulData' to
'two3node ' for 1st argument
usefulData (two3node
c)
^
main.cpp:47:5: note: candidate constructor not viable:
expects an l-value for 1st argument
usefulData(usefulData & otherusefulData)
^
main.cpp:30:5: note: candidate constructor not viable:
requires 2 arguments, but 1 was provided
usefulData (two3node* c, T m)
^
main.cpp:818:30: error: no viable overloaded '='
...s1 = rotateRight(p,r,s1.midValue,s1.child)...
~~ ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
main.cpp:36:19: note: candidate function not viable:
expects an l-value for 1st argument
usefulData operator = (usefulData & other...
^
main.cpp:945:37: error: no matching constructor for
initialization of 'usefulData'
usefulData s1;
^
main.cpp:25:5: note: candidate constructor not viable:
requires single argument 'c', but no arguments were
provided
usefulData (two3node* c)
^
main.cpp:47:5: note: candidate constructor not viable:
requires single argument 'otherusefulData', but no
arguments were provided
usefulData(usefulData & otherusefulData)
^
main.cpp:30:5: note: candidate constructor not viable:
requires 2 arguments, but 0 were provided
usefulData (two3node* c, T m)
^
main.cpp:967:15: error: no viable constructor returning
object of type 'usefulData'
return (NULL);
^ ~~~~~~
main.cpp:25:5: note: candidate constructor not viable: no
known conversion from 'usefulData' to
'two3node ' for 1st argument
usefulData (two3node
c)
^
main.cpp:47:5: note: candidate constructor not viable:
expects an l-value for 1st argument
usefulData(usefulData & otherusefulData)
^
main.cpp:30:5: note: candidate constructor not viable:
requires 2 arguments, but 1 was provided
usefulData (two3node* c, T m)
^
main.cpp:279:11: error: no viable constructor returning
object of type 'usefulData'
return (NULL);
^ ~~~~~~
main.cpp:818:33: note: in instantiation of member function
'two3Tree::rotateRight' requested here
s1 = rotateRight(p,r,s1....
^
main.cpp:741:11: note: in instantiation of member function
'two3Tree::Delete' requested here
Delete(root,d,p);
^
main.cpp:1121:19: note: in instantiation of member function
'two3Tree::deleteNode' requested here
tree1.deleteNode(data);
^
main.cpp:25:5: note: candidate constructor not viable: no
known conversion from 'usefulData' to
'two3node ' for 1st argument
usefulData (two3node
c)
^
main.cpp:47:5: note: candidate constructor not viable:
expects an l-value for 1st argument
usefulData(usefulData & otherusefulData)
^
main.cpp:30:5: note: candidate constructor not viable:
requires 2 arguments, but 1 was provided
usefulData (two3node* c, T m)
^
8 errors generated.
compiler exit status 1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant