Hello,
Following is one of the questions I've posted about 4
days ago and haven't had a response.  So, thought I'ld
repost it, just to catch the attention of some of the
Gurus out there.  This one has been killing me for a
while.

In one of the projects I'm working on, I have two
classes declared, MyObject and MyDetailsObject.

class MyDetailsObject {
 public:
  MyDetailsObject();
  virtual ~MyDetailsObject();
  ........
  .......
};

class MyObject {
 public:
  .......
  .......
  MyDetailsObject& GetDetail(Int16 index) {return
AryDetails[index];}
 private:
  CArray<MyDetailsObject,
CObjectTraits<MyDetailsObject> > AryDetails;
};

However, when I compile it in Debug Mode, it compiles
normally without even a warning.  However, in Release
Mode I get the following error:

Error : illegal operands 'MyDetailsObject *' + 'long'
(point of instantiation: 'MyObject::GetDetail(short)')
(instantiating: 'POL::CArray<MyDetailsObject,
POL::CObjectTraits<MyDetailsObject>,
POL::CCompareTraits<MyDetailsObject>>::operator[](short)')

I tried to sift through the old postings to see any
relevant messages, however, the couple of places a
similar problem is reported, it was reported as a
warning but not an error.  I'm using CodeWarrior v9.3
and am not sure what's causing this problem and how to
resolve it?  I'ld appreciate any kind of help in this
regard.

Thanks,
Kalyan Sakhamuri


__________________________________
Do you Yahoo!?
Yahoo! Search - Find what you�re looking for faster
http://search.yahoo.com

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to