mirror of
https://github.com/dart-lang/sdk
synced 2024-09-20 02:50:20 +00:00
bc7220a4fd
- make Dart2 the default option for the command line VM - add option --no-preview-dart-2 as a fallback option to run dart1 - change test scripts to use the executable dart for testing dart2 mode instead of pkg/vm/tool/dart2 - adjust numerous build and test configurations Change-Id: Id813fa5b71a89c7ec9335d3f6e83cfc9f35f86e7 Reviewed-on: https://dart-review.googlesource.com/58240 Commit-Queue: Siva Annamalai <asiva@google.com> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com> Reviewed-by: Alexander Thomas <athom@google.com> Reviewed-by: Nate Bosch <nbosch@google.com> Reviewed-by: Sigmund Cherem <sigmund@google.com> Reviewed-by: Vijay Menon <vsm@google.com>
23 lines
680 B
Dart
23 lines
680 B
Dart
// Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
//
|
|
// Simple script hanging for testing a detached process.
|
|
|
|
import 'dart:io';
|
|
import 'dart:isolate';
|
|
|
|
void main(List<String> args) {
|
|
new ReceivePort().listen(print);
|
|
|
|
// If an argument 'echo' is passed echo stdin to stdout and stderr.
|
|
if (args.length == 1 && args[0] == 'echo') {
|
|
stdin.fold(<int>[], (p, e) => p..addAll(e)).then((message) {
|
|
stdout.add(message);
|
|
stderr.add(message);
|
|
stdout.close();
|
|
stderr.close();
|
|
});
|
|
}
|
|
}
|