home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.lang.c++
- Path: sparky!uunet!infonode!vegas!gfung
- From: gfung@vegas.daisy.com (gfung@dazixca.ingr.com)
- Subject: Re: the COOL library
- Message-ID: <1992Nov11.220027.23650@infonode.ingr.com>
- Sender: usenet@infonode.ingr.com (Usenet Administrator)
- Reply-To: gfung@vegas.daisy.com
- Organization: Dazix an Intergraph Company
- References: <MCGRANT.92Nov10171811@rascals.stanford.edu>
- Distribution: usa
- Date: Wed, 11 Nov 1992 22:00:27 GMT
- Lines: 42
-
-
- I also found out there was a bug in the vector class in the ice package.
- In the Vector.h class :
-
-
- template <class Type>
- class Vector<Type> : public Vector {
- protected:
- Type* data; // Pointer to allocated storage
- static Type##_Vector_Compare compare_s; // Pointer operator== function
- void grow (long min_size); // Make the Vector bigger
-
- public:
- Vector<Type> (); // Vector v;
- Vector<Type> (unsigned long); // Vector v(10);
- Vector<Type> (void*, unsigned long); // Vector with static storage
- Vector<Type> (unsigned long, const Type&); // Vector v(10,x);
- ^^^^^^^^^^^^
- Vector<Type> (unsigned long, int, ...); // Vector v(10,3,x,y,z);
- ^^^
- ....
-
- If I declare a Vector<int> class with only two arguments.
- i.e. Vector<int> v(10,3)
-
- This declaration will satisfy both of the above constructors and causes
- compilation error.
-
- Does anyone have the fixes for it?
-
-
- Thanks
- Glenn
-
- ---
- -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- Glenn Fung | Email: gfung@dazixca.ingr.com
- Intergraph Electronics |
- 381 East Evelyn Avenue | Tel: (415)691-6420
- Mountain View, CA 94041 | Fax: (415)691-0138
- -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
-
-