blueloveTH 2 years ago
parent
commit
4a3fc95a18
1 changed files with 3 additions and 0 deletions
  1. 3 0
      src/cffi.h

+ 3 - 0
src/cffi.h

@@ -489,6 +489,9 @@ struct Int32Flags{
     uint32_t value;
     Int32Flags(uint32_t value) : value(value) {}
 
+    operator int32_t() const { return value; }
+    operator uint32_t() const { return value; }
+
     static void _register(VM* vm, PyObject* mod, PyObject* type){
         vm->bind_constructor<-1>(type, [](VM* vm, ArgsView args){
             vm->check_args_size(args.size(), 1+0, 1+1);