def load(self, string, filename=None): """Load a Polar string, checking that all inline queries succeed.""" string = to_c_str(string) filename = to_c_str(str(filename)) if filename else ffi.NULL result = lib.polar_load(self.ptr, string, filename) process_messages(self.next_message) check_result(result)
def load_str(self, string, filename): """Load a Polar string, checking that all inline queries succeed.""" string = to_c_str(string) filename = to_c_str(str(filename)) if filename else ffi.NULL check_result(lib.polar_load(self.ptr, string, filename))