C++Talk.NET Forum Index C++Talk.NET
C++ language newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

template compilation problem

 
Post new topic   Reply to topic    C++Talk.NET Forum Index -> C++ (French)
View previous topic :: View next topic  
Author Message
Allen Conway
Guest





PostPosted: Tue Feb 15, 2005 4:08 pm    Post subject: template compilation problem Reply with quote



g++ 3.4.0 ne compile pas le suivant:

template <class X> struct Xmap
{
map<string,X>::const_iterator Begin()const
{
return mXmap.begin();
}

map<string,X> mXmap;
};

::::::::::::::: error: expected ';' before "Begin"

Est-ce parce que (1) je fais une erreur de syntaxe (2) C++ ne permet pas
d'écrire ça (3) il y a un problème avec cette version du compilateur

Back to top
Falk Tannhäuser
Guest





PostPosted: Tue Feb 15, 2005 4:14 pm    Post subject: Re: template compilation problem Reply with quote



Allen Conway wrote:
Quote:
g++ 3.4.0 ne compile pas le suivant:

template <class X> struct Xmap
{
map<string,X>::const_iterator Begin()const

typename map<string,X>::const_iterator Begin() const

Falk

Back to top
Allen Conway
Guest





PostPosted: Wed Feb 16, 2005 7:44 am    Post subject: Re: template compilation problem Reply with quote



Que je suis bête! C'est comme parler une langue étrangère - il y a toujours
des règles de grammaire qu'on oublie dans un moment de panique... merci++!

"Falk Tannhäuser" <falk.tannhauser (AT) crf (DOT) canon.fr> wrote

Quote:
Allen Conway wrote:
g++ 3.4.0 ne compile pas le suivant:

template <class X> struct Xmap
{
map<string,X>::const_iterator Begin()const

typename map<string,X>::const_iterator Begin() const

Falk


Back to top
Display posts from previous:   
Post new topic   Reply to topic    C++Talk.NET Forum Index -> C++ (French) All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.