Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
関数宣言に関して質問があります。
bc で関数を宣言しました
//b.c void getNumber(); //common header common.h
ac では、次のように使用します: //ac
#include "common.h" void getInfo() { getNumber(); }
しかし、getNumberが関数の暗黙の宣言であると不平を言っていますが、その理由は何ですか?
に次の行を追加しますcommon.h
common.h
void getNumber();
bc ファイルには、この方法で関数定義が含まれている必要があります
void getNumber() { .... }