次のコードを C++ でコンパイルしようとしています。
string initialDecision ()
{
char decisionReviewUpdate;
cout << "Welcome. Type R to review, then press enter." << endl;
cin >> decisionReviewUpdate;
// Processing code
}
int main()
{
string initialDecision;
initialDecision=initialDecision();
//ERROR OCCURS HERE
// More processing code
return 0;
}
「ここでエラーが発生しました」と書かれているところに、コンパイル中に次のエラーが表示されます。