找回密码
 注册

QQ登录

只需一步,快速开始

搜索

MISRA-C-2004中文版,C语言编程规范

[复制链接]
bluesky1 发表于 2023-9-29 01:12:41 | 显示全部楼层 |阅读模式
MISRA-C-2004中文版.pdf (449.67 KB, 售价: 3 E币)
MISRA-C-:2004 Guidelines for the use of the C language in critical systems 中文版
目录
1 背景 —— C 的使用和问题 ........................................................................................ 3
1.1 汽车工业中 C 的使用.......................................................................................................... 3
1.2 语言的不安全性和 C 语言.................................................................................................. 3
1.3 安全相关系统中 C 的使用.................................................................................................. 4
1.4 标准化 .................................................................................................................................. 5
2 MISRA-C:视野.......................................................................................................... 6
2.1 MISRA-C 的发布说明........................................................................................................ 6
2.2 MISRA-C 的目标................................................................................................................ 6
3 MISRA-C:范围.......................................................................................................... 7
3.1 基本的语言问题 .................................................................................................................. 7
3.2 未指出的问题 ...................................................................................................................... 7
3.3 可应用性 .............................................................................................................................. 7
3.4 预备知识 .............................................................................................................................. 7
3.5 C++问题............................................................................................................................... 7
3.6 自动产生代码的问题 .......................................................................................................... 8
4 使用 MISRA-C............................................................................................................. 9
4.1 软件工程环境 ...................................................................................................................... 9
4.2 编程语言和编码环境 .......................................................................................................... 9
4.3 采用子集(subset) .......................................................................................................... 11
4.4 符合性声明(Claiming compliance) ............................................................................ 13
4.5 持续改进 ............................................................................................................................ 13
5 规则简介..................................................................................................................... 14
5.1 规则分类 ............................................................................................................................ 14
5.2 规则的组织 ........................................................................................................................ 14
5.3 规则的冗余 ........................................................................................................................ 14
5.4 规则的形式 ........................................................................................................................ 14
5.5 理解原始参考 .................................................................................................................... 15
5.6 规则的范围 ........................................................................................................................ 17
6 规则 ............................................................................................................................. 18
6.1 环境 .................................................................................................................................... 18
6.2 语言扩展 ............................................................................................................................ 19
6.3 文档 .................................................................................................................................... 19
6.4 字符集 ................................................................................................................................ 21
6.5 标识符 ................................................................................................................................ 212
6.6 类型 .................................................................................................................................... 23
6.7 常量 .................................................................................................................................... 24
6.8 声明与定义 ........................................................................................................................ 25
6.9 初始化 ................................................................................................................................ 27
6.10 数值类型转换 ................................................................................................................ 27
6.11 指针类型转换 .................................................................................................................... 36
6.12 表达式 ............................................................................................................................ 37
6.13 控制语句表达式 ............................................................................................................ 43
6.14 控制流 ............................................................................................................................ 45
6.15 switch 语句......................................................................................................................... 48
6.16 函数 ................................................................................................................................ 50
6.17 指针和数组 .................................................................................................................... 51
6.18 结构与联合 .................................................................................................................... 54
6.19 预处理指令 .................................................................................................................... 57
6.20 标准库 ............................................................................................................................ 62
6.21 运行时错误 .................................................................................................................... 64
7 References................................................................................................................... 66
Appendix A: Summary of rules....................................................................................... 68
Appendix B: MISRA-C :1998 到 MISRA-C :2004 规则映射 .............. 74
Appendix C:MISRA-C:1998 – 已废除的规则 .............................................................. 81
Appendix D: ISO 标准交互参考.................................................................................... 82
Appendix E : 术语表 ....................................................................................................... 85
您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|手机版|小黑屋|ELEOK |网站地图

GMT+8, 2024-12-21 22:58

Powered by Discuz! X3.5

© 2001-2024 Discuz! Team.

快速回复 返回顶部 返回列表