iso646.h

https://pubs.opengroup.org/onlinepubs/009695399/basedefs/iso646.h.html

为了允许在那些不使用某些标准运算符的键盘上编写 C 代码,它定义了一组宏。例如,在一些键盘布局上,可能没有 &&(逻辑与)、||(逻辑或)、!(逻辑非)等符号。

以下是将 iso646.h 中的宏及其对应的运算符和含义整理成表格的形式:

定义的内容
对应的运算符
含义

and

&&

and_eq

&=

位与赋值

bitand

&

位与

bitor

|

位或

compl

~

位非(按位取反)

not

!

逻辑非

not_eq

!=

不等于

or

||

or_eq

|=

或与赋值

xor

^

按位异或

xor_eq

^=

按位异或赋值

最后更新于

这有帮助吗?