Re: Templates, STL, const_iterator supported?
Re: Templates, STL, const_iterator supported?
- Subject: Re: Templates, STL, const_iterator supported?
- From: Scott Squires <email@hidden>
- Date: Thu, 19 Jan 2006 12:32:44 -0800
- Thread-topic: Templates, STL, const_iterator supported?
Title: Re: Templates, STL, const_iterator supported?
Thanks Clark, Chris and Steve for all the help.
I was a little over zealous in revamping some of the code.
That’s one section that’s working now with the feedback provided.
Thanks,
Scott
On 1/19/06 12:17 PM, "Clark Cox" <email@hidden> wrote:
> 2006/1/19, Scott Squires <email@hidden>:
> Thanks, that helped a
> lot.
>
> Are some of these GCC issues noted somewhere or is there a
> recommended
> current standards guide?
>
>
> Here's a another snag that may be
> obvious to someone. (It's been awhile for
> me)
> error: expected
> initializer before '.' token
>
> template<class Container_>
> void
> ReadContainer(MyStreamReader& ioReader, MyStreamClass& inStream,
> Container_
> &ioContainer)
> {
> long numObjects;
>
> inStream
> >> numObjects;
> for (long i = 0; i < numObjects; i++)
> {
>
> typename
> ioContainer.push_back(dynamic_cast<Container_::value_type>(ioReader.ReadAndCon
> structNextObject()));
You only need typename before types (i.e. ioContainer
> is not a type),
> try:
ioContainer.push_back(dynamic_cast<typename
Container_::value_type>(ioRe
> ader.ReadAndConstructNextObject()));
--
Clark S. Cox
> III
email@hidden
My
> CV/Resume:
http://homepage.mac.com/clarkcox3/files/Resume.pdf
http://homepage.
> mac.com/clarkcox3/files/Resume.html
_______________________________________________
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