【发布时间】:2016-08-03 16:21:42
【问题描述】:
我正在尝试使用 boost 库类进行一些套接字通信。我需要将这个变量声明为类实例,所以我声明如下,
@interface Custom_View : UIView{
boost::asio::io_service io_service_2;
tcp::resolver r_2(io_service_2);
client c_2(io_service_2);
boost::thread* dvr_thread_2;
}
越来越像错误
Custom_View.h:46:23: Unknown type name 'io_service_2'; did you mean 'boost::asio::io_service'?
Custom_View.h:47:16: Unknown type name 'io_service_2'; did you mean 'boost::asio::io_service'?
Custom_View.h:46:19: Field 'r_2' declared as a function
Custom_View.h:47:12: Field 'c_2' declared as a function
如何解决此错误。
【问题讨论】:
标签: ios objective-c boost