首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 移动开发 > Android >

没有名字的struct,该怎么解决

2012-03-19 
没有名字的structC/C++ codekernel/external/bluetooth/bluez/network/common.cstatic struct {const char

没有名字的struct

C/C++ code
kernel/external/bluetooth/bluez/network/common.cstatic struct {    const char  *name;      /* Friendly name */    const char  *uuid128;   /* UUID 128 */    uint16_t    id;     /* Service class identifier */} __svc[] = {    { "panu",   PANU_UUID,  BNEP_SVC_PANU   },    { "gn",     GN_UUID,    BNEP_SVC_GN },    { "nap",    NAP_UUID,   BNEP_SVC_NAP    },    { NULL }};


请问源码里面有些struct没有名字,这样的struct是干什么的呢?
thanks
 

[解决办法]
直接拿它定义变量,以后就不再直接使用了。
[解决办法]
楼上正解。。

热点排行