get_global method

String? get_global(
  1. String name
)

Get a global variable of a virtual machine. Return __repr__ of the result. If the variable is not found, return nullptr.

Implementation

String? get_global(String name) {
  var ret = _Bindings.pkpy_vm_get_global(pointer, StrWrapper(name).p);
  if (ret == ffi.nullptr) return null;
  String s = ret.toDartString();
  _Bindings.pkpy_delete(ret);
  return s;
}