Masm 常量按位运算

Sed*_*ail 3 64-bit assembly masm

Masm 支持常量按位运算吗?例如在 Nasm 中你可以这样写:

%define foo 00010000b
%define bar 00000011b
Run Code Online (Sandbox Code Playgroud)

...

mov r8b, foo | bar
Run Code Online (Sandbox Code Playgroud)

在 Masm 我尝试过:

foo equ 00010000b
bar equ 00000011b
Run Code Online (Sandbox Code Playgroud)

...

mov r8b, foo | bar
Run Code Online (Sandbox Code Playgroud)

导致:“错误 A2044 文件中的字符无效”

Mar*_*oom 5

MASM 的一些逻辑运算符是:

有关完整参考,请参阅MASM 运算符的官方文档。