C++ operator overloading.....problem with compiling

Please support our C++ advertiser: Intel Parallel Studio Home
Thread Solved

Join Date: Mar 2008
Posts: 4
Reputation: maggz is an unknown quantity at this point 
Solved Threads: 0
maggz maggz is offline Offline
Newbie Poster

C++ operator overloading.....problem with compiling

 
0
  #1
Mar 10th, 2008
  1. #pragma once
  2. #include <iostream>
  3. /*
  4.  * Author: Makhdoom Shah 4872
  5.  * Date of creation:22/2-2008
  6.  * Date of revision:
  7.  * Revesion #: 1
  8.  */
  9.  
  10.  
  11.  
  12. using namespace std;
  13.  
  14. //typedef double itemType; // need for another type, change it here
  15.  
  16. template<class T>
  17. class dynarray
  18. {
  19. public:
  20. dynarray( int s = 0 ); // default size is 0
  21.  
  22. dynarray( const dynarray &rhs );
  23.  
  24. const dynarray &operator=( const dynarray & rhs);
  25.  
  26. ~dynarray();
  27.  
  28. void push_back( itemType item );
  29. void push_front( T item );
  30. void add(T item);
  31. int getCap();
  32. bool isEmpty() const;
  33.  
  34. bool pop_back( );
  35.  
  36. void insert( itemType item, int pos );
  37.  
  38. T erase( int pos );
  39.  
  40. void clear( );
  41.  
  42. int size( ) const;
  43.  
  44. bool empty( ) const;
  45.  
  46. itemType &at( int pos ) const;
  47.  
  48.  
  49. // overloaded operators
  50. T &operator[]( int pos ); // non const variant
  51.  
  52. const T &operator[]( int pos ) const; // const variant
  53.  
  54. dynarray operator+( const dynarray &rhs );
  55.  
  56. dynarray &operator+=( const dynarray &rhs );
  57.  
  58. bool operator==( const dynarray &rhs );
  59.  
  60. bool operator!=( const dynarray &rhs );
  61.  
  62. friend ostream &operator<<( ostream &str, const dynarray &rhs );
  63.  
  64. private:
  65. // private functions
  66. void expand( ); // expand the array
  67.  
  68. T *dynarray; // pointer to the first element of the array
  69.  
  70. int cap; // capacity of the array
  71.  
  72. int arraySize; // size of the array
  73. };
  74.  
  75.  
  76. template<class T>
  77. dynarray<T>::dynarray(int s)
  78. {
  79. if(s>=0)
  80. {
  81. dynarray = new T[s];
  82.  
  83. for(int i=0; i <s; i++)
  84. {
  85. //theArray[i] = 0;
  86. }
  87. cap = s;
  88. arraySize = 0;
  89. }
  90. else{
  91. cerr << "Please enter a valid size: dynArray("<<s<<")"<<endl; }
  92. }
  93.  
  94. //Copy constructor
  95. template<class T>
  96. dynarray<T>::dynarray(const dynarray &rhs)
  97. {
  98. cout<< "Copy Costrustor is called now";
  99. cap = rhs.getCap();
  100. arraySize = rhs.getSize();
  101. dynarray = new T[cap];
  102. for(int i=0; i <rhs.getSize(); i++)
  103. {
  104. dynarray[i] = rhs[i];
  105. }
  106. }
  107.  
  108. //Copy assignment operator
  109. template<class T>
  110. const dynarray<T> &dynarray<T>::operator=(const dynarray & rhs)
  111. {
  112. if (this == &rhs)
  113. return *this;
  114.  
  115. delete[] dynarray; // delete old array
  116. dynarray = new T[rhs.getCap()]; // create new array with the rhs capacity
  117. cap = rhs.getCap(); // copy the capacity and the size
  118. arraySize = rhs.getSize();
  119.  
  120. for(int i=0; i <rhs.getSize(); i++)
  121. {
  122. dynarray[i] = rhs[i]; // copy all elements
  123. }
  124.  
  125. return *this;
  126. }
  127.  
  128. //deconstructor
  129. template<class T>
  130. dynarray<T>::~dynarray()
  131. {
  132. delete[] dynarray;
  133. }
  134. // Insert new item at first possition in array
  135. template<class T>
  136. void dynarray<T>::push_front(T item)
  137. {
  138. // increase the size of array
  139. arraySize++;
  140.  
  141. // move all elements one possition
  142. for(int i=arraySize;i>1;i--)
  143. dynarray[i-1] = dynarray[i-2];
  144.  
  145. // add new elemets to first pos
  146. dynarray[0] = item;
  147. }
  148.  
  149. template<class T>
  150. void dynarray<T>::push_back(T item)
  151. {
  152. add(item);
  153. }
  154.  
  155. template<class T>
  156. bool dynarray<T>::pop_back( )
  157. {
  158. T temp =0;
  159. if(arraySize>0)
  160. {
  161. arraySize--;
  162. //temp = theArray[arraySize];
  163. //theArray[arraySize]=0;
  164. return 1;
  165. }
  166. //return temp;
  167. return 0;
  168.  
  169. }
  170. // add new item to last possition in array
  171. template<class T>
  172. void dynarray<T>::add(T item)
  173. {
  174. // expand if needed
  175. if(arraySize>=cap)
  176. expand();
  177.  
  178. dynarray[arraySize] = item;
  179. arraySize++;
  180. empty = false;
  181. }
  182.  
  183. // insert an item anywhere in the array
  184. template<class T>
  185. void dynarray<T>::insert(T item, int pos)
  186. {
  187. // return if possition is invalid
  188. if(pos>arraySize)
  189. return;
  190.  
  191. // move all elements to make room for new item
  192. arraySize++;
  193. for(int i=arraySize;i>pos;i--)
  194. dynarray[i-1] = dynarray[i-2];
  195.  
  196. // insert new item
  197. dynarray[pos] = item;
  198. empty = false;
  199. }
  200. // delete one possition in array
  201. template<class T>
  202. T dynarray<T>::erase(int pos)
  203. {
  204. // returns if possition is invalid
  205. if(pos>=arraySize)
  206. {
  207. cerr << "Index out of bounds: erase("<<pos<<")"<<endl;
  208. return;
  209. }
  210.  
  211. T temp = dynarray[pos];
  212. arraySize--;
  213.  
  214. //move all elements
  215. for(int i=pos;i<arraySize;i++)
  216. dynarray[i] = dynarray[i+1];
  217. return temp;
  218. }
  219.  
  220. // delete all elements in the array
  221. template<class T>
  222. void dynarray<T>::clear()
  223. {
  224. //T *temp = new T[cap];
  225. //delete theArray;
  226. arraySize=0;
  227. // return *this;
  228. }
  229. // get capacity of array
  230. template<class T>
  231. int dynarray<T>::getCap() const
  232. {
  233. return cap;
  234.  
  235. }
  236. // get size of array
  237. template<class T>
  238. int dynarray<T>::getSize() const
  239. {
  240. return arraySize;
  241.  
  242. }
  243.  
  244. // return if array is empty or not
  245. template<class T>
  246. bool dynarray<T>::isEmpty() const
  247. {
  248. if(arraySize==0)
  249. return true;
  250.  
  251. return false;
  252. }
  253. // change size of array, only if array is empty
  254. template<class T>
  255. void dynarray<T>::reSize(int s)
  256. {
  257. if(s>arraySize)
  258. {
  259. cap = s;
  260. cout << cap << endl;
  261. }
  262. else
  263. {
  264. cerr << "Index out of bounds: reSize("<<s<<")"<<endl;
  265. }
  266. }
  267.  
  268. // print all elements in the array
  269. template<class T>
  270. void dynarray<T>::printArray()
  271. { cout<<"[";
  272. for(int i=0; i<arraySize; i++)
  273. {
  274. cout<<dynarray[i];
  275. if(i!=arraySize-1)
  276. cout<<",";
  277. }
  278. cout << "]" << endl;
  279. }
  280.  
  281. template<class T>
  282. T &dynarray<T>::operator[]( int pos )
  283. {
  284. return dynarray[pos];
  285. }
  286.  
  287. // const variant
  288. template<class T>
  289. const T &dynarray<T>::operator[]( int pos ) const
  290. {
  291. double temp = dynarray[pos];
  292. return temp;
  293. }
  294.  
  295. // add two arrays together, can cascade
  296. template<class T>
  297. dynarray<T> &dynarray<T>:: operator+( const Array &rhs )
  298. {
  299. // create a temp array to hold the adds
  300. dynarray temp;
  301.  
  302. // put first array in temp
  303. for(int k=0;k<this->arraySize;k++)
  304. temp.add(this->dynarray[k]);
  305.  
  306. // put second array in temp
  307. for(int i=0;i<rhs.getSize();i++)
  308. temp.add(rhs[i]);
  309.  
  310. // return temp array
  311. return temp;
  312. }
  313. // test if array is equal to another array or not equal
  314. template<class T>
  315. bool dynarray<T>::operator!=( const dynarray<T> &rhs )
  316. {
  317. // run test only if the size of both arrays are equal
  318. if(!(*this == rhs))
  319. {
  320. return true;
  321. }
  322.  
  323. return false;
  324. }
  325. template <class T>
  326. void dynarray<T>::ascendSort()
  327. {
  328. int i, j;
  329. T temp;
  330. for(i = 0; i < this->arSize; i++)
  331. {
  332. for(j = i + 1; j < this->arSize; j++)
  333. {
  334. if (this->anArray[i] > this->anArray[j])
  335. {
  336. temp = this->anArray[i];
  337. this->anArray[i] = this->anArray[j];
  338. this->anArray[j] = temp;
  339. }
  340. }
  341. }
  342. for (int f = 0;f<this->arSize;f++)
  343. {
  344. cout<<anArray[f];
  345. }
  346. }
  347.  
  348. template <class T>
  349. void dynarray<T>::descendSort()
  350. {
  351. int i, j;
  352. T temp;
  353. for(i = 0; i < this->arSize; i++)
  354. {
  355. for(j = i + 1; j < this->arSize; j++)
  356. {
  357. if (this->anArray[i] < this->anArray[j])
  358. {
  359. temp = this->anArray[i];
  360. this->anArray[i] = this->anArray[j];
  361. this->anArray[j] = temp;
  362. }
  363. }
  364. }
  365.  
  366. for (int f = 0;f<this->arSize;f++)
  367. {
  368. cout<<anArray[f];
  369. }
  370. }
  371. void main()
  372. {
  373. dynarray<T> ary;
  374. ary.insert(2.0,0);
  375. ary.insert(2.0,1);
  376. ary.insert(2.0,2);
  377. ary.insert(3.0,3);
  378. ////?*?*?*??*?*?*?*??*?*?*?*?*?*?*?*??**??*?*?*?*??*?*?*?*?*?*?*?*??**
  379. //Testing of Insert method
  380. ///?*?*?*??*?*?*?*?*?*??*?*??*?*?*??*?*?*?*?*?*?*??*?*?*?*?*?*?*?*??**
  381. cout<<"This is Insert Method Test Start"<<endl;
  382. cout<<ary<<endl;
  383. cout<<"This is Insert Method Test End"<<endl;
  384. ary.push_back(7.0);
  385. ary.push_back(8.0);
  386. cout<<"This is Push_back Method Test Start"<<endl;
  387. cout<<ary<<endl;
  388. cout<<endl;
  389. //////?*?*?*??*?*?*?*??*?*?*?*?*?*?*?*??**??*?*?*?*??*?*?*?*?*?*?*?*??**
  390. ////Testing of Push_back method
  391. /////?*?*?*??*?*?*?*?*?*??*?*??*?*?*??*?*?*?*?*?*?*??*?*?*?*?*?*?*?*??**
  392. cout<<"This is Push_back Method Test End"<<endl;
  393. cout<<"This is erase Method Test Start"<<endl;
  394. ary.erase(3);
  395. //////?*?*?*??*?*?*?*??*?*?*?*?*?*?*?*??**??*?*?*?*??*?*?*?*?*?*?*?*??**
  396. ////Testing of Erase method
  397. /////?*?*?*??*?*?*?*?*?*??*?*??*?*?*??*?*?*?*?*?*?*??*?*?*?*?*?*?*?*??**
  398. cout<<"This is erase Method Test End"<<endl;
  399. cout<<endl;
  400. //////?*?*?*??*?*?*?*??*?*?*?*?*?*?*?*??**??*?*?*?*??*?*?*?*?*?*?*?*??**
  401. ////Testing of Clear method Uncomment to run it
  402. cout<<"This is the size Method Test Start"<<endl;
  403. cout<<ary.size()<<endl;
  404. //////?*?*?*??*?*?*?*??*?*?*?*?*?*?*?*??**??*?*?*?*??*?*?*?*?*?*?*?*??**
  405. ////Testing of size method
  406. /////?*?*?*??*?*?*?*?*?*??*?*??*?*?*??*?*?*?*?*?*?*??*?*?*?*?*?*?*?*??**
  407. cout<<"This is size Method Test End"<<endl;
  408. cout<<endl;
  409. cout<<endl;
  410. //////?*?*?*??*?*?*?*??*?*?*?*?*?*?*?*??**??*?*?*?*??*?*?*?*?*?*?*?*??**
  411. ////Testing of empty method
  412. /////?*?*?*??*?*?*?*?*?*??*?*??*?*?*??*?*?*?*?*?*?*??*?*?*?*?*?*?*?*??**
  413. cout<<"This is the empty Method Test Start"<<endl;
  414. cout<<ary.empty()<<endl;
  415. cout<<"This is empty Method Test End"<<endl;
  416. cout<<endl;
  417. //////?*?*?*??*?*?*?*??*?*?*?*?*?*?*?*??**??*?*?*?*??*?*?*?*?*?*?*?*??**
  418. ////Testing of at method
  419. /////?*?*?*??*?*?*?*?*?*??*?*??*?*?*??*?*?*?*?*?*?*??*?*?*?*?*?*?*?*??**
  420. cout<<"This is the at Method Test Start"<<endl;
  421. cout<<ary.at(2)<<endl;
  422. cout<<"This is at Method Test End"<<endl;
  423. cout<<endl;
  424.  
  425. //////?*?*?*??*?*?*?*??*?*?*?*?*?*?*?*??**??*?*?*?*??*?*?*?*?*?*?*?*??**
  426. ////Testing of overloaded [] Operator
  427. /////?*?*?*??*?*?*?*?*?*??*?*??*?*?*??*?*?*?*?*?*?*??*?*?*?*?*?*?*?*??**
  428. cout<<"This is the [] operator Test Start"<<endl;
  429. cout<<ary.operator [](2)<<endl;
  430. cout<<"This is at Method Test End"<<endl;
  431. cout<<endl;
  432.  
  433. //////?*?*?*??*?*?*?*??*?*?*?*?*?*?*?*??**??*?*?*?*??*?*?*?*?*?*?*?*??**
  434. ////Testing of Descending and ascending algorithm test
  435. /////?*?*?*??*?*?*?*?*?*??*?*??*?*?*??*?*?*?*?*?*?*??*?*?*?*?*?*?*?*??**
  436. //
  437. cout<<"This is unsorted array"<<endl;
  438. dynarray<T> aryy;
  439. aryy.insert(4.0,0);
  440. aryy.insert(6.0,1);
  441. aryy.insert(3.0,2);
  442. aryy.insert(7.0,3);
  443. cout<<aryy<<endl;
  444. cout<<"This is asending sorted array"<<endl;
  445. aryy.ascendSort();
  446. cout<<endl;
  447. cout<<"This is desending sorted array"<<endl;
  448. aryy.descendSort(
  449. );
  450. cout<<endl;
_____________________________________________________

compile output:


1>------ Build started: Project: dynarray, Configuration: Debug Win32 ------
1>Compiling...
1>dynarray.cpp
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(28) : error C2061: syntax error : identifier 'itemType'
1> c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(73) : see reference to class template instantiation 'dynarray<T>' being compiled
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(36) : error C2061: syntax error : identifier 'itemType'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(46) : error C2143: syntax error : missing ';' before '&'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(46) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(46) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(46) : warning C4183: 'at': missing return type; assumed to be a member function returning 'int'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(68) : error C2461: 'dynarray<T>' : constructor syntax missing formal parameters
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(153) : error C2244: 'dynarray<T>::push_back' : unable to match function definition to an existing declaration
1> c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(28) : see declaration of 'dynarray<T>::push_back'
1> definition
1> 'void dynarray<T>::push_back(T)'
1> existing declarations
1> 'void dynarray<T>::push_back(void)'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(199) : error C2244: 'dynarray<T>::insert' : unable to match function definition to an existing declaration
1> c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(36) : see declaration of 'dynarray<T>::insert'
1> definition
1> 'void dynarray<T>::insert(T,int)'
1> existing declarations
1> 'void dynarray<T>::insert(void)'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(235) : error C2244: 'dynarray<T>::getCap' : unable to match function definition to an existing declaration
1> c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(31) : see declaration of 'dynarray<T>::getCap'
1> definition
1> 'int dynarray<T>::getCap(void) const'
1> existing declarations
1> 'int dynarray<T>::getCap(void)'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(242) : error C2039: 'getSize' : is not a member of 'dynarray<T>'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(266) : error C2039: 'reSize' : is not a member of 'dynarray<T>'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(279) : error C2039: 'printArray' : is not a member of 'dynarray<T>'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(297) : error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(297) : error C2143: syntax error : missing ',' before '&'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(312) : error C2244: 'dynarray<T>::operator +' : unable to match function definition to an existing declaration
1> c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(54) : see declaration of 'dynarray<T>::operator +'
1> definition
1> 'dynarray<T> &dynarray<T>::operator +(const int)'
1> existing declarations
1> 'dynarray<T> dynarray<T>::operator +(const dynarray<T> &)'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(346) : error C2039: 'ascendSort' : is not a member of 'dynarray<T>'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(370) : error C2039: 'descendSort' : is not a member of 'dynarray<T>'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(373) : error C2065: 'T' : undeclared identifier
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(373) : error C2133: 'ary' : unknown size
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(373) : error C2512: 'dynarray' : no appropriate default constructor available
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(374) : error C2660: 'dynarray<T>::insert' : function does not take 2 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(375) : error C2660: 'dynarray<T>::insert' : function does not take 2 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(376) : error C2660: 'dynarray<T>::insert' : function does not take 2 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(377) : error C2660: 'dynarray<T>::insert' : function does not take 2 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(382) : error C2679: binary '<<' : no operator found which takes a right-hand operand of type 'dynarray' (or there is no acceptable conversion)
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(653): could be 'std::basic_ostream<_Elem,_Traits> &std::operator <<<char,std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(700): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<char,std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(738): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(785): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(909): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const signed char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(916): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,signed char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(923): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const unsigned char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(930): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,unsigned char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(170): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_ostream<_Elem,_Traits> &(__cdecl *)(std::basic_ostream<_Elem,_Traits> &))'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(176): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_ios<_Elem,_Traits> &(__cdecl *)(std::basic_ios<_Elem,_Traits> &))'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(183): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::ios_base &(__cdecl *)(std::ios_base &))'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(190): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::_Bool)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(210): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(short)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(243): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned short)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(263): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__w64 int)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(288): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__w64 unsigned int)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(308): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(long)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(328): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__w64 unsigned long)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(349): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__int64)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(369): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned __int64)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(390): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(float)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(410): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(double)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(430): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(long double)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(450): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(const void *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(470): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_streambuf<_Elem,_Traits> *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> while trying to match the argument list '(std::ostream, dynarray)'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(384) : error C2660: 'dynarray<T>::push_back' : function does not take 1 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(385) : error C2660: 'dynarray<T>::push_back' : function does not take 1 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(387) : error C2679: binary '<<' : no operator found which takes a right-hand operand of type 'dynarray' (or there is no acceptable conversion)
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(653): could be 'std::basic_ostream<_Elem,_Traits> &std::operator <<<char,std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(700): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<char,std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(738): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(785): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(909): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const signed char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(916): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,signed char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(923): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const unsigned char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(930): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,unsigned char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(170): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_ostream<_Elem,_Traits> &(__cdecl *)(std::basic_ostream<_Elem,_Traits> &))'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(176): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_ios<_Elem,_Traits> &(__cdecl *)(std::basic_ios<_Elem,_Traits> &))'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(183): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::ios_base &(__cdecl *)(std::ios_base &))'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(190): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::_Bool)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(210): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(short)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(243): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned short)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(263): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__w64 int)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(288): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__w64 unsigned int)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(308): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(long)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(328): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__w64 unsigned long)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(349): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__int64)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(369): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned __int64)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(390): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(float)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(410): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(double)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(430): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(long double)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(450): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(const void *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(470): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_streambuf<_Elem,_Traits> *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> while trying to match the argument list '(std::ostream, dynarray)'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(394) : error C2662: 'dynarray<T>::erase' : cannot convert 'this' pointer from 'dynarray' to 'dynarray<T> &'
1> Reason: cannot convert from 'dynarray' to 'dynarray<T>'
1> Conversion requires a second user-defined-conversion operator or constructor
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(403) : error C2662: 'dynarray<T>::size' : cannot convert 'this' pointer from 'dynarray' to 'const dynarray<T> &'
1> Reason: cannot convert from 'dynarray' to 'const dynarray<T>'
1> Conversion requires a second user-defined-conversion operator or constructor
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(414) : error C2662: 'dynarray<T>::empty' : cannot convert 'this' pointer from 'dynarray' to 'const dynarray<T> &'
1> Reason: cannot convert from 'dynarray' to 'const dynarray<T>'
1> Conversion requires a second user-defined-conversion operator or constructor
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(421) : error C2662: 'dynarray<T>::at' : cannot convert 'this' pointer from 'dynarray' to 'const dynarray<T> &'
1> Reason: cannot convert from 'dynarray' to 'const dynarray<T>'
1> Conversion requires a second user-defined-conversion operator or constructor
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(429) : error C2663: 'dynarray<T>::operator []' : 2 overloads have no legal conversion for 'this' pointer
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(438) : error C2065: 'T' : undeclared identifier
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(438) : error C2133: 'aryy' : unknown size
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(438) : error C2512: 'dynarray' : no appropriate default constructor available
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(439) : error C2660: 'dynarray<T>::insert' : function does not take 2 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(440) : error C2660: 'dynarray<T>::insert' : function does not take 2 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(441) : error C2660: 'dynarray<T>::insert' : function does not take 2 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(442) : error C2660: 'dynarray<T>::insert' : function does not take 2 arguments
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(443) : error C2679: binary '<<' : no operator found which takes a right-hand operand of type 'dynarray' (or there is no acceptable conversion)
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(653): could be 'std::basic_ostream<_Elem,_Traits> &std::operator <<<char,std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(700): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<char,std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(738): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(785): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(909): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const signed char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(916): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,signed char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(923): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,const unsigned char *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(930): or 'std::basic_ostream<_Elem,_Traits> &std::operator <<<std::char_traits<char>>(std::basic_ostream<_Elem,_Traits> &,unsigned char)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(170): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_ostream<_Elem,_Traits> &(__cdecl *)(std::basic_ostream<_Elem,_Traits> &))'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(176): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_ios<_Elem,_Traits> &(__cdecl *)(std::basic_ios<_Elem,_Traits> &))'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(183): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::ios_base &(__cdecl *)(std::ios_base &))'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(190): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::_Bool)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(210): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(short)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(243): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned short)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(263): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__w64 int)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(288): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__w64 unsigned int)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(308): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(long)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(328): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__w64 unsigned long)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(349): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(__int64)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(369): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(unsigned __int64)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(390): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(float)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(410): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(double)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(430): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(long double)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(450): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(const void *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> c:\program files\microsoft visual studio 9.0\vc\include\ostream(470): or 'std::basic_ostream<_Elem,_Traits> &std::basic_ostream<_Elem,_Traits>::operator <<(std::basic_streambuf<_Elem,_Traits> *)'
1> with
1> [
1> _Elem=char,
1> _Traits=std::char_traits<char>
1> ]
1> while trying to match the argument list '(std::ostream, dynarray)'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(445) : error C2039: 'ascendSort' : is not a member of 'dynarray'
1> c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(18) : see declaration of 'dynarray'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(448) : error C2039: 'descendSort' : is not a member of 'dynarray'
1> c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(18) : see declaration of 'dynarray'
1>c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.cpp(7) : fatal error C1075: end of file found before the left brace '{' at 'c:\users\makhdoom shah\documents\visual studio 2008\projects\dynarray\dynarray\dynarray.h(372)' was matched
1>Build log was saved at "file://c:\Users\Makhdoom Shah\Documents\Visual Studio 2008\Projects\dynarray\dynarray\Debug\BuildLog.htm"
1>dynarray - 44 error(s), 1 warning(s)
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========
Last edited by Narue; Mar 10th, 2008 at 12:14 pm. Reason: Added code tags.
Reply With Quote Quick reply to this message  
Join Date: Sep 2004
Posts: 7,580
Reputation: Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute 
Solved Threads: 709
Team Colleague
Narue's Avatar
Narue Narue is offline Offline
Code Goddess

Re: C++ operator overloading.....problem with compiling

 
0
  #2
Mar 10th, 2008
So...did you even try to understand and correct the errors you're getting before posting all of that (without code tags)?
I'm here to prove you wrong.
Reply With Quote Quick reply to this message  
Join Date: Mar 2008
Posts: 4
Reputation: maggz is an unknown quantity at this point 
Solved Threads: 0
maggz maggz is offline Offline
Newbie Poster

Re: C++ operator overloading.....problem with compiling

 
0
  #3
Mar 10th, 2008
i tried but i got confuse...
Reply With Quote Quick reply to this message  
Join Date: Sep 2004
Posts: 7,580
Reputation: Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute Narue has a reputation beyond repute 
Solved Threads: 709
Team Colleague
Narue's Avatar
Narue Narue is offline Offline
Code Goddess

Re: C++ operator overloading.....problem with compiling

 
1
  #4
Mar 10th, 2008
Programmers are always confused. It's a fact of life. So start at the top and go one error at a time. Often one error will cause others, and the cascade effect overwhelms you. So don't treat it as 44 errors and 1 warning that you don't understand, treat it as
dynarray.h(28) : error C2061: syntax error : identifier 'itemType'
Ask yourself, "what is itemType?", and "why wouldn't my compiler recognize it?".
I'm here to prove you wrong.
Reply With Quote Quick reply to this message  
Reply

This thread has been marked solved.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC