CX51 用户手册----NOCOND 伪指令

本文介绍了Keil C51编译器中NOCOND伪指令的用法,该指令用于排除未参与编译的代码行在列表文件中的显示。文章通过示例展示了如何使用此指令,并解释了其默认设置及与COND指令的区别。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

声明:

1、本翻译仅供个人学习使用,本人没有提供技术支持的义务,也不承担由此引发的任何后果。

2、请勿用于商业用途。

3、英文来自:http://www.keil.com/support/man/docs/c51/。

4、欢迎大家共同与我交流探讨(290207203@qq.com)。


NOCOND Compiler Directive

Abbreviation

NOCO

Arguments

None.

Default

COND

µVision

Options — Listing — C Compiler Listing — Conditional.

Description

The NOCOND directive excludes lines omitted from compilation from the listing file.

See Also

COND

Example

The following example shows the listing file for a source file compiled with the NOCONDdirective:

.
.
.
stmt level  source
   1        extern unsigned char  a, b;
   2               unsigned char     c;
   3
   4        main()
   5        {
   6   1    #if defined (VAX)
   9   1      b = 14;
  10   1      a = 15;
  11   1    #endif
  12   1    }
.
.
.


NOCOND 编译器伪指令

缩写

NOCO

参数

无。

缺省

COND

µVision

Options — Listing — C Compiler Listing — Conditional.

描述

NOCOND 伪指令指示列表文件不包含编译忽略的行。 

参考

COND

示例

下面的示例显示使用NOCOND伪指令编译的源文件生成的列表文件:

.
.
.
stmt level  source
   1        extern unsigned char  a, b;
   2               unsigned char     c;
   3
   4        main()
   5        {
   6   1    #if defined (VAX)
   9   1      b = 14;
  10   1      a = 15;
  11   1    #endif
  12   1    }
.
.
.




评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值