作者kbjs (kk)
看板EE_DSnP
标题[问题] hw5 一开始compile就不过 看不出原因
时间Sun May 17 19:24:18 2009
一开始compile就不过 看不出原因
讯息如下:
Cleaning util...
Cleaning main...
Removing libutil.a...
Removing adtTest.array...
Checking util...
> compiling: myGetChar.cpp
> compiling: myString.cpp
> compiling: util.cpp
In file included from util.cpp:10:
myUsage.h: In member function a€?double MyUsage::checkMem() consta€?:
myUsage.h:71: error: a€?strncmpa€? was not declared in this scope
myUsage.h:72: error: a€?strchra€? was not declared in this scope
make[1]: *** [util.o] Error 1
Checking main...
> compiling: adtTest.cpp
In file included from ../../include/util.h:14,
from adtTest.cpp:10:
../../include/myUsage.h: In member function a€?double MyUsage::checkMem() consta€?:
../../include/myUsage.h:71: error: a€?strncmpa€? was not declared in this scope
../../include/myUsage.h:72: error: a€?strchra€? was not declared in this scope
make[1]: *** [adtTest.o] Error 1
make: *** [main] Error 2
麻烦老师助教解答
谢谢
--
※ 发信站: 批踢踢实业坊(ptt.cc)
◆ From: 140.112.243.224
1F:→ keyboardle:在myUsage.h里加上#include <string.h>大概能解决 05/17 19:56
2F:→ kbjs:还是不能过 一样的讯息 谢谢 05/17 20:00
3F:推 WSzc:那加上 #include <cstring> 试试 05/17 20:17
4F:→ kbjs:过了!! 感恩 多谢 05/17 20:20