在Go中-类似于NOP(汇编程序)命令吗?
调试时,我经常需要设置一个条件断点,例如:在Go中-类似于NOP(汇编程序)命令吗?,go,Go,调试时,我经常需要设置一个条件断点,例如: if messageType == 1 { nop; // <-- breakpoint } 如果messageType==1{ 不;//只是不要将其存储在实变量中: 如果messageType==1{ _ = 1 } 您不能为空白标识设置断点吗?这是否回答了您的问题? if messageType == 1 { x = 1; // <-- breakpoint }
if messageType == 1 {
nop; // <-- breakpoint
}
如果messageType==1{
不;//只是不要将其存储在实变量中:
如果messageType==1{
_ = 1
}
您不能为空白标识设置断点吗?这是否回答了您的问题?
if messageType == 1 {
x = 1; // <-- breakpoint
}