Errors
Code:
mystring.hpp:49: error: destructors may not have parameters
mystring.hpp: In constructor `mystring::mystring()':
mystring.hpp:40: error: expected primary-expression before '->' token
mystring.hpp:41: error: expected primary-expression before '->' token
mystring.hpp: In constructor `mystring::mystring(const char*)':
mystring.hpp:45: error: invalid conversion from `const char*' to `char*'
mystring.hpp:45: error: initializing argument 1 of `mystring& mystring::newString(char*)'
mystring.hpp: In destructor `mystring::~mystring()':
mystring.hpp:50: error: `theString' undeclared (first use this function)
mystring.hpp:50: error: (Each undeclared identifier is reported only once for each function it appears in.)
mystring.cpp: At global scope:
mystring.cpp:27: error: prototype for `mystring& mystring::newString(const char*)' does not match any in class `mystring'
mystring.hpp:53: error: candidate is: mystring& mystring::newString(char*)
mystring.cpp: In member function `mystring& mystring::newString(const char*)':
mystring.cpp:32: error: expression in new-declarator must have integral or enumeration type
mystring.cpp:37: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:38: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:40: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:42: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:43: error: request for member `size' in `*newString', which is of non-class type `STRING*'
mystring.cpp:43: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:45: error: request for member `size' in `*newString', which is of non-class type `STRING*'
mystring.cpp:57: error: invalid initialization of reference of type 'mystring&' from expression of type 'STRING**'
mystring.cpp: At global scope:
mystring.cpp:64: error: `INPUT' does not name a type
mystring.cpp: In member function `mystring& mystring::destroyString(mystring&)':
mystring.cpp:88: error: base operand of `->' has non-pointer type `mystring'
mystring.cpp:89: error: type `class mystring' argument given to `delete', expected pointer
mystring.cpp: In member function `char* mystring::charAt(mystring&, int)':
mystring.cpp:102: error: base operand of `->' has non-pointer type `mystring'
mystring.cpp:104: error: base operand of `->' has non-pointer type `mystring'
mystring.cpp: In member function `mystring& mystring::operator+(mystring&)':
mystring.cpp:120: error: expected primary-expression before ']' token
mystring.cpp:125: error: request for member `size' in `*newString', which is of non-class type `STRING*'
mystring.cpp:125: error: request for member `size' in `this', which is of non-class type `mystring* const'
mystring.cpp:125: error: base operand of `->' has non-pointer type `mystring'
mystring.cpp:126: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:126: error: request for member `size' in `*newString', which is of non-class type `STRING*'
mystring.cpp:127: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:129: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:131: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:131: error: `string1' undeclared (first use this function)
mystring.cpp:132: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:132: error: base operand of `->' has non-pointer type `mystring'
mystring.cpp:134: error: request for member `size' in `*newString', which is of non-class type `STRING*'
mystring.cpp:134: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:135: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:135: error: request for member `theString' in `this', which is of non-class type `mystring* const'
mystring.cpp:136: error: request for member `theString' in `*newString', which is of non-class type `STRING*'
mystring.cpp:136: error: request for member `size' in `this', which is of non-class type `mystring* const'
mystring.cpp:136: error: base operand of `->' has non-pointer type `mystring'
mystring.cpp:148: error: invalid initialization of reference of type 'mystring&' from expression of type 'STRING**'
mystring.cpp: In member function `void mystring::printString(mystring&)':
mystring.cpp:163: error: base operand of `->' has non-pointer type `mystring'
mystring.cpp:164: error: base operand of `->' has non-pointer type `mystring'
*** Error code 1
make: Fatal error: Command failed for target `mystring.o'