Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: std::map<>::iterator in Xcode 2.1



set gcc 3.3 as you compiler
and you should be ok

On Oct 28, 2005, at 5:53 PM, Red Marble Games wrote:

After an upgrade to 2.1, some of my code stopped working and I can't tell why.  In a header file in which I defined a templated class as follows: template<class E, class T> class CDataStore{ ... etc., which includes a private member declared as std::map<E, T*> m_data_list.  So far so good.  But the same header file defines a method of the CDataStore class called release(), and not surprisingly the release() method starts out with:

std::map<E, T*>::iterator iter;

XCode doesn't seem to recognize the iterator declaration; the error reads "error: expected ';' before 'iter'".  This code compiled fine in Xcode 1.5.  The file #includes <map>, and the declaration of the std::map is fine; it just chokes on the iterator declaration.  Any ideas? 

Thanks,

Mark Batten

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

Dmitry Markman


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/xcode-users/email@hidden

This email sent to email@hidden

References: 
 >std::map<>::iterator in Xcode 2.1 (From: Red Marble Games <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.