Skip to content

Commit

Permalink
fix dart
Browse files Browse the repository at this point in the history
  • Loading branch information
csukuangfj committed Jul 26, 2024
1 parent a57e5e3 commit 94800c2
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions flutter/sherpa_onnx/lib/src/sherpa_onnx_bindings.dart
Original file line number Diff line number Diff line change
Expand Up @@ -489,7 +489,7 @@ typedef SherpaOnnxCreateOnlineStreamWithHotwords
typedef IsOnlineStreamReadyNative = Int32 Function(
Pointer<SherpaOnnxOnlineRecognizer>, Pointer<SherpaOnnxOnlineStream>);

typedef SherpaOnnxIsOnlineStreamReady = int Function(
typedef IsOnlineStreamReady = int Function(
Pointer<SherpaOnnxOnlineRecognizer>, Pointer<SherpaOnnxOnlineStream>);

typedef SherpaOnnxDecodeOnlineStreamNative = Void Function(
Expand Down Expand Up @@ -841,7 +841,7 @@ class SherpaOnnxBindings {
static SherpaOnnxCreateOnlineStreamWithHotwords?
createOnlineStreamWithHotwords;

static SherpaOnnxIsOnlineStreamReady? isOnlineStreamReady;
static IsOnlineStreamReady? isOnlineStreamReady;

static SherpaOnnxDecodeOnlineStream? decodeOnlineStream;

Expand Down Expand Up @@ -1096,7 +1096,7 @@ class SherpaOnnxBindings {
.asFunction();

isOnlineStreamReady ??= dynamicLibrary
.lookup<NativeFunction<SherpaOnnxIsOnlineStreamReadyNative>>(
.lookup<NativeFunction<IsOnlineStreamReadyNative>>(
'SherpaOnnxIsOnlineStreamReady')
.asFunction();

Expand All @@ -1115,7 +1115,8 @@ class SherpaOnnxBindings {
.asFunction();

isEndpoint ??= dynamicLibrary
.lookup<NativeFunction<IsEndpointNative>>('SherpaOnnxIsEndpoint')
.lookup<NativeFunction<IsEndpointNative>>(
'SherpaOnnxOnlineStreamIsEndpoint')
.asFunction();

destroyOnlineStreamResultJson ??= dynamicLibrary
Expand Down

0 comments on commit 94800c2

Please sign in to comment.