Xcode 9 遇到:Implicit declaration
2017-10-27 本文已影响1222人
AnderQZ
最近经常遇到这个报错:
Implicit declaration of function 'select' is invalid in C99
还有这个:
Declaration of 'select' must be imported from module 'Darwin.POSIX.sys.time' before it is required
如下图:
Screen Shot 2017-10-27 at 15.19.00.png解决办法:
导入头文件:#include <sys/time.h>