File tree Expand file tree Collapse file tree 1 file changed +9
-8
lines changed
Expand file tree Collapse file tree 1 file changed +9
-8
lines changed Original file line number Diff line number Diff line change @@ -55,27 +55,28 @@ func Basic() error {
5555 output .StdoutHr ()
5656
5757 // 特定のビットが立っているか検査
58+ //goland:noinspection GoBoolExpressions
5859 if x & (1 << 5 ) != 0 {
5960 output .Stdoutl ("[x&(1<<5)]" , "ON" )
6061 }
6162
6263 output .StdoutHr ()
6364
6465 // 特定のビットを落とす
65- x &^= ( 1 << 5 )
66- output .Stdoutf ("[x &^= ( 1 << 5) ]" , "%08b\n " , x )
66+ x &^= 1 << 5
67+ output .Stdoutf ("[x &^= 1 << 5]" , "%08b\n " , x )
6768
6869 // 特定のビットを立てる
69- x |= ( 1 << 5 )
70- output .Stdoutf ("[x |= ( 1 << 5) ]" , "%08b\n " , x )
70+ x |= 1 << 5
71+ output .Stdoutf ("[x |= 1 << 5]" , "%08b\n " , x )
7172
7273 output .StdoutHr ()
7374
7475 // 特定のビットをトグル
75- x ^= ( 1 << 7 )
76- output .Stdoutf ("[x ^= ( 1 << 7) ]" , "%08b\n " , x )
77- x ^= ( 1 << 7 )
78- output .Stdoutf ("[x ^= ( 1 << 7) ]" , "%08b\n " , x )
76+ x ^= 1 << 7
77+ output .Stdoutf ("[x ^= 1 << 7]" , "%08b\n " , x )
78+ x ^= 1 << 7
79+ output .Stdoutf ("[x ^= 1 << 7]" , "%08b\n " , x )
7980
8081 output .StdoutHr ()
8182
You can’t perform that action at this time.
0 commit comments