Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- "/usr/bin/make" -f nbproject/Makefile-Debug.mk QMAKE=/usr/lib/qt4/bin/qmake SUBPROJECTS= .build-conf
- make[1]: Entering directory '/home/jarrah/Documents/Dropbox/C++/TOC++'
- /usr/lib/qt4/bin/qmake VPATH=. -o qttmp-Debug.mk nbproject/qt-Debug.pro
- mv -f qttmp-Debug.mk nbproject/qt-Debug.mk
- "/usr/bin/make" -f nbproject/qt-Debug.mk dist/Debug/GNU-Linux-x86/TOC__
- make[2]: Entering directory '/home/jarrah/Documents/Dropbox/C++/TOC++'
- g++ -c -pipe -std=c++11 -g -Wall -W -D_REENTRANT -DQT_GUI_LIB -DQT_CORE_LIB -DQT_SHARED -I/usr/share/qt4/mkspecs/linux-g++ -Inbproject -I/usr/include/qt4/QtCore -I/usr/include/qt4/QtGui -I/usr/include/qt4 -I. -Inbproject -I. -o build/Debug/GNU-Linux-x86/ProductDatabase.o src/ProductDatabase.cpp
- In file included from src/ProductDatabase.cpp:10:0:
- src/Product.cpp:35:1: error: prototype for ‘Product::Product()’ does not match any in class ‘Product’
- Product::Product()
- ^
- src/Product.cpp:10:7: error: candidates are: Product::Product(Product&&)
- class Product {
- ^
- src/Product.cpp:10:7: error: Product::Product(const Product&)
- src/Product.cpp:16:2: error: Product::Product(std::string, long int, long int)
- Product(std::string, long, long);
- ^
- src/ProductDatabase.cpp: In constructor ‘ProductDatabase::ProductDatabase()’:
- src/ProductDatabase.cpp:51:34: error: no matching function for call to ‘Product::Product()’
- ProductDatabase::ProductDatabase()
- ^
- src/ProductDatabase.cpp:51:34: note: candidates are:
- In file included from src/ProductDatabase.cpp:10:0:
- src/Product.cpp:41:1: note: Product::Product(std::string, long int, long int)
- Product::Product(std::string extName, long extProductPrice, long extBarCode)
- ^
- src/Product.cpp:41:1: note: candidate expects 3 arguments, 0 provided
- src/Product.cpp:10:7: note: Product::Product(const Product&)
- class Product {
- ^
- src/Product.cpp:10:7: note: candidate expects 1 argument, 0 provided
- src/Product.cpp:10:7: note: Product::Product(Product&&)
- src/Product.cpp:10:7: note: candidate expects 1 argument, 0 provided
- src/ProductDatabase.cpp:53:30: error: no matching function for call to ‘Product::Product()’
- allProducts = new Product[47];
- ^
- src/ProductDatabase.cpp:53:30: note: candidates are:
- In file included from src/ProductDatabase.cpp:10:0:
- src/Product.cpp:41:1: note: Product::Product(std::string, long int, long int)
- Product::Product(std::string extName, long extProductPrice, long extBarCode)
- ^
- src/Product.cpp:41:1: note: candidate expects 3 arguments, 0 provided
- src/Product.cpp:10:7: note: Product::Product(const Product&)
- class Product {
- ^
- src/Product.cpp:10:7: note: candidate expects 1 argument, 0 provided
- src/Product.cpp:10:7: note: Product::Product(Product&&)
- src/Product.cpp:10:7: note: candidate expects 1 argument, 0 provided
- src/ProductDatabase.cpp:53:14: error: no match for ‘operator=’ (operand types are ‘std::vector<Product>’ and ‘Product*’)
- allProducts = new Product[47];
- ^
- src/ProductDatabase.cpp:53:14: note: candidates are:
- In file included from /usr/include/c++/4.9.1/vector:69:0,
- from src/ProductDatabase.cpp:9:
- /usr/include/c++/4.9.1/bits/vector.tcc:167:5: note: std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(const std::vector<_Tp, _Alloc>&) [with _Tp = Product; _Alloc = std::allocator<Product>]
- vector<_Tp, _Alloc>::
- ^
- /usr/include/c++/4.9.1/bits/vector.tcc:167:5: note: no known conversion for argument 1 from ‘Product*’ to ‘const std::vector<Product>&’
- In file included from /usr/include/c++/4.9.1/vector:64:0,
- from src/ProductDatabase.cpp:9:
- /usr/include/c++/4.9.1/bits/stl_vector.h:448:7: note: std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(std::vector<_Tp, _Alloc>&&) [with _Tp = Product; _Alloc = std::allocator<Product>]
- operator=(vector&& __x) noexcept(_Alloc_traits::_S_nothrow_move())
- ^
- /usr/include/c++/4.9.1/bits/stl_vector.h:448:7: note: no known conversion for argument 1 from ‘Product*’ to ‘std::vector<Product>&&’
- /usr/include/c++/4.9.1/bits/stl_vector.h:470:7: note: std::vector<_Tp, _Alloc>& std::vector<_Tp, _Alloc>::operator=(std::initializer_list<_Tp>) [with _Tp = Product; _Alloc = std::allocator<Product>]
- operator=(initializer_list<value_type> __l)
- ^
- /usr/include/c++/4.9.1/bits/stl_vector.h:470:7: note: no known conversion for argument 1 from ‘Product*’ to ‘std::initializer_list<Product>’
- src/ProductDatabase.cpp: In member function ‘int ProductDatabase::setDatabaseProduct(int, std::string, long int, long int)’:
- src/ProductDatabase.cpp:61:28: error: no match for ‘operator=’ (operand types are ‘__gnu_cxx::__alloc_traits<std::allocator<Product> >::value_type {aka Product}’ and ‘Product*’)
- allProducts[logicalSize] = new Product(name, price, barCode);
- ^
- src/ProductDatabase.cpp:61:28: note: candidates are:
- In file included from src/ProductDatabase.cpp:10:0:
- src/Product.cpp:10:7: note: Product& Product::operator=(const Product&)
- class Product {
- ^
- src/Product.cpp:10:7: note: no known conversion for argument 1 from ‘Product*’ to ‘const Product&’
- src/Product.cpp:10:7: note: Product& Product::operator=(Product&&)
- src/Product.cpp:10:7: note: no known conversion for argument 1 from ‘Product*’ to ‘Product&&’
- src/ProductDatabase.cpp:67:50: error: no matching function for call to ‘ProductDatabase::resizeDatabase(bool, std::vector<Product>*)’
- allProducts = resizeDatabase(true, &allProducts);
- ^
- src/ProductDatabase.cpp:67:50: note: candidates are:
- src/ProductDatabase.cpp:44:7: note: void ProductDatabase::resizeDatabase(bool)
- void resizeDatabase(bool);
- ^
- src/ProductDatabase.cpp:44:7: note: candidate expects 1 argument, 2 provided
- src/ProductDatabase.cpp:45:23: note: std::vector<Product> ProductDatabase::resizeDatabase(bool, std::vector<Product>)
- std::vector<Product> resizeDatabase(bool, std::vector<Product>);
- ^
- src/ProductDatabase.cpp:45:23: note: no known conversion for argument 2 from ‘std::vector<Product>*’ to ‘std::vector<Product>’
- src/ProductDatabase.cpp: At global scope:
- src/ProductDatabase.cpp:57:45: warning: unused parameter ‘productNo’ [-Wunused-parameter]
- int ProductDatabase::setDatabaseProduct(int productNo, std::string name, long price, long barCode)
- ^
- src/ProductDatabase.cpp: In member function ‘std::string ProductDatabase::getDatabase(int)’:
- src/ProductDatabase.cpp:76:21: error: no match for ‘operator!=’ (operand types are ‘__gnu_cxx::__alloc_traits<std::allocator<Product> >::value_type {aka Product}’ and ‘char’)
- if(allProducts[i] != '\0') {
- ^
- src/ProductDatabase.cpp:80:28: error: base operand of ‘->’ has non-pointer type ‘__gnu_cxx::__alloc_traits<std::allocator<Product> >::value_type {aka Product}’
- output += allProducts[i]->getData();
- ^
- src/ProductDatabase.cpp: In member function ‘int ProductDatabase::delProduct(int)’:
- src/ProductDatabase.cpp:105:52: error: no matching function for call to ‘ProductDatabase::resizeDatabase(bool, std::vector<Product>*)’
- allProducts = resizeDatabase(false, &allProducts);
- ^
- src/ProductDatabase.cpp:105:52: note: candidates are:
- src/ProductDatabase.cpp:44:7: note: void ProductDatabase::resizeDatabase(bool)
- void resizeDatabase(bool);
- ^
- src/ProductDatabase.cpp:44:7: note: candidate expects 1 argument, 2 provided
- src/ProductDatabase.cpp:45:23: note: std::vector<Product> ProductDatabase::resizeDatabase(bool, std::vector<Product>)
- std::vector<Product> resizeDatabase(bool, std::vector<Product>);
- ^
- src/ProductDatabase.cpp:45:23: note: no known conversion for argument 2 from ‘std::vector<Product>*’ to ‘std::vector<Product>’
- src/ProductDatabase.cpp: In member function ‘std::string* ProductDatabase::getUserNames()’:
- src/ProductDatabase.cpp:124:35: error: expected primary-expression before ‘[’ token
- std::string* output = std::string[logicalSize];
- ^
- src/ProductDatabase.cpp: In member function ‘bool ProductDatabase::productExists(std::string, long int)’:
- src/ProductDatabase.cpp:144:21: error: no match for ‘operator!=’ (operand types are ‘__gnu_cxx::__alloc_traits<std::allocator<Product> >::value_type {aka Product}’ and ‘char’)
- if(allProducts[i] != '\0' && allProducts[i].getName() == extProductName && allProducts[i].getBarCode == extBarCode) {
- ^
- src/ProductDatabase.cpp:144:107: error: invalid use of member function (did you forget the ‘()’ ?)
- if(allProducts[i] != '\0' && allProducts[i].getName() == extProductName && allProducts[i].getBarCode == extBarCode) {
- ^
- src/ProductDatabase.cpp: In member function ‘bool ProductDatabase::productExists(long int)’:
- src/ProductDatabase.cpp:156:21: error: no match for ‘operator!=’ (operand types are ‘__gnu_cxx::__alloc_traits<std::allocator<Product> >::value_type {aka Product}’ and ‘char’)
- if(allProducts[i] != '\0' && allProducts[i].getBarCode() == extBarCode && allProducts[i].canBuy()) {
- ^
- src/ProductDatabase.cpp:156:92: error: ‘__gnu_cxx::__alloc_traits<std::allocator<Product> >::value_type’ has no member named ‘canBuy’
- if(allProducts[i] != '\0' && allProducts[i].getBarCode() == extBarCode && allProducts[i].canBuy()) {
- ^
- src/ProductDatabase.cpp: In member function ‘std::vector<Product> ProductDatabase::resizeDatabase(bool, std::vector<Product>)’:
- src/ProductDatabase.cpp:170:41: error: could not convert ‘resizing.std::vector<_Tp, _Alloc>::resize<Product, std::allocator<Product> >(((std::vector<Product>::size_type)((ProductDatabase*)this)->ProductDatabase::allProductsSize))’ from ‘void’ to ‘std::vector<Product>’
- return resizing.resize(allProductsSize);
- ^
- src/ProductDatabase.cpp:174:41: error: could not convert ‘resizing.std::vector<_Tp, _Alloc>::resize<Product, std::allocator<Product> >(((std::vector<Product>::size_type)((ProductDatabase*)this)->ProductDatabase::allProductsSize))’ from ‘void’ to ‘std::vector<Product>’
- return resizing.resize(allProductsSize);
- ^
- src/ProductDatabase.cpp: In member function ‘int ProductDatabase::partition(int, int, bool (ProductDatabase::*)(Product*, Product*, bool))’:
- src/ProductDatabase.cpp:187:10: error: no matching function for call to ‘Product::Product()’
- Product temp;
- ^
- src/ProductDatabase.cpp:187:10: note: candidates are:
- In file included from src/ProductDatabase.cpp:10:0:
- src/Product.cpp:41:1: note: Product::Product(std::string, long int, long int)
- Product::Product(std::string extName, long extProductPrice, long extBarCode)
- ^
- src/Product.cpp:41:1: note: candidate expects 3 arguments, 0 provided
- src/Product.cpp:10:7: note: Product::Product(const Product&)
- class Product {
- ^
- src/Product.cpp:10:7: note: candidate expects 1 argument, 0 provided
- src/Product.cpp:10:7: note: Product::Product(Product&&)
- src/Product.cpp:10:7: note: candidate expects 1 argument, 0 provided
- src/ProductDatabase.cpp:190:45: error: must use ‘.*’ or ‘->*’ to call pointer-to-member function in ‘test (...)’, e.g. ‘(... ->* test) (...)’
- while(test(allProducts[left], pivotElement) && left + 1 < max) {
- ^
- src/ProductDatabase.cpp:193:46: error: must use ‘.*’ or ‘->*’ to call pointer-to-member function in ‘test (...)’, e.g. ‘(... ->* test) (...)’
- while(test(allProducts[right], pivotElement) && right-1 > 0) {
- ^
- src/ProductDatabase.cpp: In member function ‘int ProductDatabase::writeOutDatabase(std::string)’:
- src/ProductDatabase.cpp:261:29: error: variable ‘std::ofstream outfile’ has initializer but incomplete type
- std::ofstream outfile (path);
- ^
- src/ProductDatabase.cpp: In member function ‘int ProductDatabase::adminWriteOutDatabase(std::string)’:
- src/ProductDatabase.cpp:284:29: error: variable ‘std::ofstream outfile’ has initializer but incomplete type
- std::ofstream outfile (path);
- ^
- src/ProductDatabase.cpp:294:54: error: expected primary-expression before ‘<<’ token
- outfile << "The total for this bill is: " + total; << '\n';
- ^
- src/ProductDatabase.cpp: In member function ‘int ProductDatabase::readDatabase(std::string)’:
- src/ProductDatabase.cpp:312:28: error: variable ‘std::ifstream inFile’ has initializer but incomplete type
- std::ifstream inFile (path);
- ^
- /usr/include/c++/4.9.1/bits/stl_construct.h: In instantiation of ‘void std::_Construct(_T1*, _Args&& ...) [with _T1 = Product; _Args = {}]’:
- /usr/include/c++/4.9.1/bits/stl_uninitialized.h:515:43: required from ‘static void std::__uninitialized_default_n_1<_TrivialValueType>::__uninit_default_n(_ForwardIterator, _Size) [with _ForwardIterator = Product*; _Size = long unsigned int; bool _TrivialValueType = false]’
- /usr/include/c++/4.9.1/bits/stl_uninitialized.h:570:33: required from ‘void std::__uninitialized_default_n(_ForwardIterator, _Size) [with _ForwardIterator = Product*; _Size = long unsigned int]’
- /usr/include/c++/4.9.1/bits/stl_uninitialized.h:631:50: required from ‘void std::__uninitialized_default_n_a(_ForwardIterator, _Size, std::allocator<_Tp>&) [with _ForwardIterator = Product*; _Size = long unsigned int; _Tp = Product]’
- /usr/include/c++/4.9.1/bits/vector.tcc:549:39: required from ‘void std::vector<_Tp, _Alloc>::_M_default_append(std::vector<_Tp, _Alloc>::size_type) [with _Tp = Product; _Alloc = std::allocator<Product>; std::vector<_Tp, _Alloc>::size_type = long unsigned int]’
- /usr/include/c++/4.9.1/bits/stl_vector.h:676:41: required from ‘void std::vector<_Tp, _Alloc>::resize(std::vector<_Tp, _Alloc>::size_type) [with _Tp = Product; _Alloc = std::allocator<Product>; std::vector<_Tp, _Alloc>::size_type = long unsigned int]’
- src/ProductDatabase.cpp:170:41: required from here
- /usr/include/c++/4.9.1/bits/stl_construct.h:75:7: error: no matching function for call to ‘Product::Product()’
- { ::new(static_cast<void*>(__p)) _T1(std::forward<_Args>(__args)...); }
- ^
- /usr/include/c++/4.9.1/bits/stl_construct.h:75:7: note: candidates are:
- In file included from src/ProductDatabase.cpp:10:0:
- src/Product.cpp:41:1: note: Product::Product(std::string, long int, long int)
- Product::Product(std::string extName, long extProductPrice, long extBarCode)
- ^
- src/Product.cpp:41:1: note: candidate expects 3 arguments, 0 provided
- src/Product.cpp:10:7: note: Product::Product(const Product&)
- class Product {
- ^
- src/Product.cpp:10:7: note: candidate expects 1 argument, 0 provided
- src/Product.cpp:10:7: note: Product::Product(Product&&)
- src/Product.cpp:10:7: note: candidate expects 1 argument, 0 provided
- src/ProductDatabase.cpp: In member function ‘std::vector<Product> ProductDatabase::resizeDatabase(bool, std::vector<Product>)’:
- src/ProductDatabase.cpp:180:1: warning: control reaches end of non-void function [-Wreturn-type]
- }
- ^
- nbproject/qt-Debug.mk:215: recipe for target 'build/Debug/GNU-Linux-x86/ProductDatabase.o' failed
- make[2]: *** [build/Debug/GNU-Linux-x86/ProductDatabase.o] Error 1
- make[2]: Leaving directory '/home/jarrah/Documents/Dropbox/C++/TOC++'
- nbproject/Makefile-Debug.mk:65: recipe for target '.build-conf' failed
- make[1]: *** [.build-conf] Error 2
- make[1]: Leaving directory '/home/jarrah/Documents/Dropbox/C++/TOC++'
- nbproject/Makefile-impl.mk:39: recipe for target '.build-impl' failed
- make: *** [.build-impl] Error 2
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement