ce8bd6d17a
This minor change makes it a bit easier to consume ddc as a library. Change-Id: Ie98a4fa78c313d827cf1a395b26a4f7859a9413c Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/220120 Reviewed-by: Nicholas Shahan <nshahan@google.com> Commit-Queue: Joshua Litt <joshualitt@google.com>
22 lines
772 B
Dart
22 lines
772 B
Dart
#!/usr/bin/env dart
|
|
// Copyright (c) 2021, 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.
|
|
|
|
// @dart = 2.9
|
|
|
|
/// Command line entry point for Dart Development Compiler (dartdevc), used to
|
|
/// compile a collection of dart libraries into a single JS module
|
|
|
|
import 'dart:isolate';
|
|
|
|
import 'package:dev_compiler/ddc.dart' as ddc;
|
|
|
|
/// The entry point for the Dart Dev Compiler.
|
|
///
|
|
/// [sendPort] may be passed in when started in an isolate. If provided, it is
|
|
/// used for bazel worker communication instead of stdin/stdout.
|
|
Future main(List<String> args, [SendPort sendPort]) async {
|
|
return ddc.internalMain(args, sendPort);
|
|
}
|