voila ce qu'il a voulu dire...
Code :
- #include <string>
- using namespace std;
- class Exception {
- protected:
- string * erreur;
- public:
- Exception(){erreur = new string;}
- Exception(string & message);
- Exception(const Exception & e);
- virtual ~Exception(){delete erreur;}
- string getError();
- };
|
Bizarre ton pointeur : string *. Si tu veux remplacer un vieux char *, tu as seulement besoin d'un string tout court.
Cordialement,
xteR.
Message édité par xterminhate le 19-03-2004 à 19:50:55