MISRA C:2023 Dir 4.1
Run-time failures shall be minimized
自 R2024a 起
描述
指令定义
Run-time failures shall be minimized 1 .
理由
为优化可执行代码的大小和速度,C 标准实现了有限的运行时失败检查。为减少运行时失败,请检查以下错误:
算术错误
指针算术
数组边界错误
函数参数
指针解引用
动态内存
Polyspace 实现
如果您的代码中存在运行时问题,则 Polyspace® 会报告违反此指令的行为,包括:
故障排除
如果您预计存在违规,但未看到该违规,请参阅Diagnose Why Coding Standard Violations Do Not Appear as Expected。
检查信息
组:代码设计 |
类别:必需 |
AGC 类别:必需 |
版本历史记录
在 R2024a 中推出
另请参阅
检查 MISRA C:2023 (-misra-c-2023)
| MISRA C:2023 Rule 1.3
| MISRA C:2023 Rule 18.1
| MISRA C:2023 Rule 18.2
| MISRA C:2023 Rule 18.3
1 All MISRA coding rules and directives are © Copyright The MISRA Consortium Limited 2021.
The MISRA coding standards referenced in the Polyspace Bug Finder™ documentation are from the following MISRA standards:
MISRA C:2004
MISRA C:2012
MISRA C:2023
MISRA C++:2008
MISRA C++:2023
MISRA and MISRA C are registered trademarks of The MISRA Consortium Limited 2021.