sdlStrtoull function

int sdlStrtoull(
  1. String? str,
  2. Pointer<Pointer<Int8>> endp,
  3. int base
)
extern DECLSPEC Uint64 SDLCALL SDL_strtoull(const char *str, char **endp, int base)

Implementation

int sdlStrtoull(String? str, Pointer<Pointer<Int8>> endp, int base) {
  final sdlStrtoullLookupFunction = libSdl2.lookupFunction<
      Uint64 Function(
          Pointer<Utf8> str, Pointer<Pointer<Int8>> endp, Int32 base),
      int Function(Pointer<Utf8> str, Pointer<Pointer<Int8>> endp,
          int base)>('SDL_strtoull');
  final strPointer = str != null ? str.toNativeUtf8() : nullptr;
  final result = sdlStrtoullLookupFunction(strPointer, endp, base);
  calloc.free(strPointer);
  return result;
}