| Index: pkg/dartino_compiler/lib/src/worker/developer.dart
|
| diff --git a/pkg/dartino_compiler/lib/src/worker/developer.dart b/pkg/dartino_compiler/lib/src/worker/developer.dart
|
| index 2e9ba85a25356366232eebf3ad73584d100fded5..67af217fee316d1dcba0a01c06eee2d26c46e300 100644
|
| --- a/pkg/dartino_compiler/lib/src/worker/developer.dart
|
| +++ b/pkg/dartino_compiler/lib/src/worker/developer.dart
|
| @@ -24,6 +24,9 @@ import 'dart:io' show
|
| ProcessResult,
|
| SocketException;
|
|
|
| +import 'dart:typed_data' show
|
| + Uint8List;
|
| +
|
| import 'package:sdk_services/sdk_services.dart' show
|
| OutputService,
|
| SDKServices,
|
| @@ -83,8 +86,7 @@ import '../verbs/infrastructure.dart' show
|
| throwFatalError;
|
|
|
| import '../../vm_context.dart' show
|
| - DartinoVmContext,
|
| - SinkDebugListener;
|
| + DartinoVmContext;
|
|
|
| import '../../incremental/dartino_compiler_incremental.dart' show
|
| IncrementalCompilationFailed;
|
| @@ -131,6 +133,8 @@ import '../vm_connection.dart' show
|
| import '../dartino_compiler_options.dart' show
|
| DartinoCompilerOptions;
|
|
|
| +import '../../vm_context.dart' show DebugListener;
|
| +
|
| import '../hub/exit_codes.dart' show
|
| INPUT_ERROR;
|
|
|
| @@ -259,6 +263,22 @@ Future<Null> attachToVmTcp(String host, int port, SessionState state) async {
|
| await attachToVm(connection, state);
|
| }
|
|
|
| +class SinkDebugListener extends DebugListener {
|
| + final Sink stdoutSink;
|
| + final Sink stderrSink;
|
| + SinkDebugListener(this.stdoutSink, this.stderrSink);
|
| +
|
| + // Notification of bytes written to stdout.
|
| + writeStdOut(int processId, Uint8List data) {
|
| + stdoutSink.add(data);
|
| + }
|
| +
|
| + // Notification of bytes written stderr.
|
| + writeStdErr(int processId, Uint8List data) {
|
| + stderrSink.add(data);
|
| + }
|
| +}
|
| +
|
| Future<Null> attachToVm(
|
| VmConnection connection,
|
| SessionState state,
|
|
|