Skip to content

Commit

Permalink
add missing annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesdixon committed Oct 24, 2022
1 parent c2e0a18 commit 37439e3
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions lib/src/compute.dart
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ import 'package:flutter_isolate/flutter_isolate.dart';
/// Both the return type and the [message] type must be supported by
/// [SendPort.send] stated in
/// https://api.dart.dev/stable/dart-isolate/SendPort/send.html
@pragma('vm:entry-point')
Future<T> flutterCompute<T, U>(
FutureOr<T> Function(U message) callback, U message) async {
final callbackHandle =
Expand Down Expand Up @@ -57,6 +58,7 @@ enum _Status {
error,
}

@pragma('vm:entry-point')
Future<void> _isolateMain(Map<String, dynamic> config) async {
final port = config["port"] as SendPort;
try {
Expand Down

0 comments on commit 37439e3

Please sign in to comment.