19 lines
209 B
Go
19 lines
209 B
Go
|
package allegro5
|
||
|
|
||
|
// #include <stdlib.h>
|
||
|
import "C"
|
||
|
|
||
|
type flagMut struct {
|
||
|
flg C.int
|
||
|
}
|
||
|
|
||
|
func (m *flagMut) Set(f C.int) {
|
||
|
m.flg |= f
|
||
|
}
|
||
|
|
||
|
func (m *flagMut) Unset(f C.int) {
|
||
|
if m.flg&f == f {
|
||
|
m.flg ^= f
|
||
|
}
|
||
|
}
|