help-gplusplus
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: how to resolve this one


From: Jeffrey Holle
Subject: Re: how to resolve this one
Date: Wed, 18 May 2005 09:17:34 -0500
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040115

You are including the list header, but using a map.
Include <map> instead and do not forget to somehow open up the std namespace.
Additionally, why not use make_pair?  As in:
  op.insert(make_pair(CNodeTransformer::OPTIMIZATION_TYPE,optType));

kushal.mnit@gmail.com wrote:
 are porting an application from Windows to Linux. The native code is
in VC++.
We're getting the following error in g++ for the code given below...

the code in vc++ is :
#include <list>

146     map<int,int> op;
147     op.insert(pair<int,int<(CNodeTransformer::OPTIMIZATION_TYPE,
optType));

we are getting error in gc++ :

CMapperFlow.cpp: In member function `int
   CMapperFlow::mainMapper(CFlowEntities&)':
CMapperFlow.cpp:147: parse error before `<' token
CMapperFlow.cpp:147: parse error before `)' token

Has anyone got a soln for it...





reply via email to

[Prev in Thread] Current Thread [Next in Thread]