array type has incomplete element type

extern   struct  SoundReport SoundList[32];     ///// 多写了  struct

typedef struct

{

u8 SoundContent[50];//语音播报的内容 注:以null为结束标志

const char Priority; //语音播报优先级  注:10为最高,0为最低

char Len;
//声音数据长度

char Flag;
//标识位

// char *Str;
//声音标识

} SoundReport;

既然 已经  typedef  , 那么   SoundRepor 就 类似于 int , 不需要 在前面添加  struct  。

//// 摘录笔记

在C中定义一个结构体类型要用typedef:

    typedef
struct Student

    {

    int a;

    }Stu;

    于是在声明变量的时候就可:Stu stu1;(如果没有typedef就必须用struct
Student stu1;来声明)

    这里的Stu实际上就是struct Student的别名。Stu==struct
Student

    

另外这里也可以不写Student(于是也不能struct Student stu1;了,必须是Stu stu1;)

    typedef
struct

    {

    int a;

    }Stu;

    但在c++里很简单,直接

    struct
Student

    {

    int a;

    };    

    于是就定义了结构体类型Student,声明变量时直接Student stu2;

Debug : array type has incomplete element type的更多相关文章

  1. 编译binutil包报错 error: array type has incomplete element type extern const struct relax_type md_relax_table[];

    安装lfs时编译binutils出错: ../../sources/binutils-2.15.91.0.2/gas/config/tc-i386.h:457:32: error: array typ ...

  2. The content of element type "sqlMapConfig" is incomplete,

    The content of element type "sqlMapConfig" is incomplete, it must match "(properties? ...

  3. Array types are now written with the brackets around the element type问题的解决方法

    在xcode6.1中来编写swift空数组时.出现的的这个问题,依照官方 Swift 教程<The Swift Programming Language>来写 let emptyArray ...

  4. Attribute "resultType" must be declared for element type "insert"或"update"

    Attribute "resultType" must be declared for element type "insert"或"update&q ...

  5. Multiple annotations found at this line: - The content of element type "mapper" must match "EMPTY". - Attribute "namespace" must be declared for element type "mapper".

    今天在mybatis的mapper映射配置文件中遇到了这样的问题,困扰了我3个小时: Multiple annotations found at this line: - The content of ...

  6. The content of element type "configuration" must match "(properties?,settings?,typeAliases?,typeHandlers?,objectFactory?,objectWrapperFactory?,reflectorFactory?,plugins?,environments?,databaseIdProv

    在mybatis配置文件config.xml中报错: The content of element type "configuration" must match "(p ...

  7. The content of element type "package" must match "(result-types?,interceptors?...

    错误:“The content of element type "package" must match "(result-types?,interceptors?,de ...

  8. The content of element type "configuration" must match "(properties?,settings?,typeAliases?,typeHandlers?,objectFactory?...

    <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE configuration PUBLIC & ...

  9. Open quote is expected for attribute "property" associated with an element type "result".错误

    java  Mybatis 框架下的项目 报   Open quote is expected for attribute "property" associated with a ...

随机推荐

  1. EasyUI 之 easyui-datagrid 字段格式化

    后台返回的json格式: 列表字段要显示username 用户的真实姓名: formatter="formatterByUserName" <table id="d ...

  2. jquery得到焦点和失去焦点

    鼠标在搜索框中点击的时候里面的文字就消失了,经常会用到搜索框的获得焦点和失去焦点的事件,接下来介绍一下具体代码,感兴趣的朋友额可以参考下   input失去焦点和获得焦点 鼠标在搜索框中点击的时候里面 ...

  3. mysql中 groupby分组

    引用自http://www.cnblogs.com/mo-beifeng/archive/2012/02/07/2341886.html#2341105 --按某一字段分组取最大(小)值所在行的数据 ...

  4. [Apple开发者帐户帮助]六、配置应用服务(5.3)推送通知(APN):从您的Web服务器发送推送通知

    要使用APN从Web服务器向macOS用户发送推送通知,请注册网站推送标识符并创建网站推送证书. 对于每个网站,请注册一个网站推送标识符,用于验证通知是否来自您的服务器.然后创建一个网站推送证书以签署 ...

  5. 设计模式 | 适配器模式(adapter)

    定义: 将一个类的接口转换成客户希望的另外一个接口.Adapter模式使得原本由于接口不兼容而不能一起工作的那些类可以一起工作.   书中说到Gof的设计模式中,讲了两种类型的适配器模式: 1.类适配 ...

  6. jQuery使用手册,【新手必备】

    jQuery是一款同prototype一样优秀js开发库类,特别是对css和XPath的支持,使我们写js变得更加方便!如果你不是个js高手又想写出优 秀的js效果,jQuery可以帮你达到目的!   ...

  7. mailto的使用

    用mailto会使用Windows自带的邮件进行发送邮件 方式一,代码如下: [注意:一下表单元素中的 name的值不能改变] <form action="mailto:lisi@12 ...

  8. 简单的KKL诊断线~~~自己在家都可以制作obd诊断接口了 ~~

    简单的KKL诊断线~~~自己在家都可以制作~~ 适合bmw 07年以前的车型,因为新的车型使用D-can作为诊断接口,所以不能再使用kkl诊断接口不过SB开头的宝马3系还是可以使用的 更多内容欢迎查看 ...

  9. [ POI 2011 ] Dynamite

    \(\\\) \(Description\) 一棵\(N\)个节点的树,树上有\(M\)个节点是关键点,选出\(K\)个特殊点,使得所有关键点到特殊点的距离中最大的最小,输出最大值最小为多少. \(N ...

  10. C#通过SqlConnection连接查询更新等操作Sqlserver数据库

    Sqlserver数据库连接方式有多种,这里只介绍最常用的通过SqlConnection和Sqlserver数据库用户名和密码验证来进行操作数据库. 数据库连接字符串: string connStri ...