[debutant]erreur int to string alors qu il n y a pas de int
Citation:
main.cpp:
Error E2285 main.cpp 12: Could not find a match for 'plane::plane(int)' in funct
ion main()
Error E2031 main.cpp 12: Cannot cast from 'int' to 'plane' in function main()
*** 2 errors in Compile ***
voila dans le main :
plane p= plane('abcd');
Pourquoi il me dit que c'est un int ? Pourtant j'ai definit la fonction de cette fac on :
Code:
1 2 3 4 5 6 7 8 9
|
plane(string a);
plane::plane(string a)
{
cout << "the plane is called " << name<< endl;
landingGearOn=true;
} |
Il n' y pas dint bon dieu ! Pourquoi il em fait ca alors ?