[問題] class
使用語言:C++
程式碼(網頁版):http://ideone.com/3ZYMNl
錯誤訊息:
prog.cpp: In function 'int main()':
prog.cpp:85:21: error: expected primary-expression before 'void'
check_my_engine(void);
^
prog.cpp:85:25: error: 'check_my_engine' was not declared in this scope
check_my_engine(void);
預期結果:class Car中的函式check_my_engine,
能順利的在main中輸出Engine的資訊
--
※ 發信站: 批踢踢實業坊(ptt.cc), 來自: 140.113.112.32
※ 文章網址: https://www.ptt.cc/bbs/C_and_CPP/M.1439264274.A.EC9.html
推
08/11 12:54, , 1F
08/11 12:54, 1F
→
08/11 13:15, , 2F
08/11 13:15, 2F
→
08/11 13:17, , 3F
08/11 13:17, 3F
※ 編輯: cactaceae (140.113.112.32), 08/11/2015 13:32:22
推
08/11 13:38, , 4F
08/11 13:38, 4F
→
08/11 13:42, , 5F
08/11 13:42, 5F
→
08/11 13:51, , 6F
08/11 13:51, 6F
※ 編輯: cactaceae (140.113.112.32), 08/11/2015 13:55:14
→
08/11 14:09, , 7F
08/11 14:09, 7F
好的!瞭解!再去好好研究一下!謝謝大家的解答~
※ 編輯: cactaceae (140.113.112.32), 08/11/2015 16:06:21
討論串 (同標題文章)