编译时报错: error: <strong>two or more data types in declaration specifiers</strong> error:two or more
来源:互联网 发布:淘宝装修消除模块间距 编辑:程序博客网 时间:2024/06/05 10:15
编译时某个文件报错:
error:two or more data types in declaration specifiers
原因可能有两个:
1. 少了一个分号";",比如定义一个结构体时,在最后忘了加分号。
解决方法:加上分号即可。
2. 重复定义,比如:a.h文件中有如下定义:
#define bool char
#define bool charb.h文件中有如下定义:
typedefcharbool;
typedef char bool;然后在c文件中同时包含a.h和b.h:
#include "a.h"
#include "b.h"
#include "a.h"#include "b.h"
此时,就会报这个错。
解决方法:去掉其中一处定义。
阅读全文
0 0
- 编译时报错: error: <strong>two or more data types in declaration specifiers</strong> error:two or more
- error: two or more data types in declaration specifiers
- error: two or more data types in declaration specifiers
- error: two or more data types in declaration specifiers
- 【Linux】【Debug】编译错误error: two or more data types in declaration specifiers
- error: two or more data types in declaration specifiers原因及解决方法
- error: two or more data types in declaration specifiers原因及解决方法
- error: two or more data types in declaration specifiers原因及解决方法
- error: two or more data types in declaration specifiers原因及解决方法 [转]
- error: two or more data types in declaration specifiers原因及解决方法
- two or more data types in declaration specifiers
- Error: two or more data types in declaration of `main'
- error: two or more data types in declaration of 'main'
- two or more data types in declaration of 错误
- two+or+more+data+types+in+declaration+of+`main'
- two or more data types in declaration of
- two or more data types in declaration of `main'
- two or more data types in declaration of `函数名'的报错
- 机器学习之线性模型
- 百度云一面--面经
- TypeScript使用心得
- JVM -XX: 参数介绍
- 自定义RecyclerView实现QQ侧滑删除按钮
- 编译时报错: error: <strong>two or more data types in declaration specifiers</strong> error:two or more
- MYSQL-创建数据表
- 常见网络攻击方式
- UVa1062
- [iOS]系统TabBar简单使用
- c拾遗
- 震网三代在metasploit-framework上的复现与利用
- 浅谈机器学习用来做什么,它是如果工作的
- iOS之《Effective Objective-C 2.0》读书笔记(17)