Commit graph

34 commits

Author SHA1 Message Date
Sigmund Cherem 8415b70e75 [dart2js] recommend using 'dart compile js'.
This is the first deprecation step, moving towards having dart2js
under the more general dart command line interface.

Going forward 'dart compile js' is the recommended way to invoke
dart2js.

This CL adds:
* an internal flag used to detect how was dart2js invoked and
  provide a warning when invoked in an unsupported way.
* ensures the flag is provided in the dart cli, as well as our
  (developer's only) scripts. These scripts will likely move to a
  different location in the future. Note that the `dart2js_sdk*`
  scripts are not providing this flag (these are the script that get
  eventually shipped with our built SDK), as such, invokations of the
  dart2js binary will show the new warning.

Change-Id: I96e40ecf01598eadab20dfc59114f5fff7438084
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/229062
Reviewed-by: Joshua Litt <joshualitt@google.com>
Commit-Queue: Sigmund Cherem <sigmund@google.com>
2022-01-21 16:42:40 +00:00
Lasse R.H. Nielsen d352bc28b8 Remove (most) uses of the "non-nullable" experiment flag.
Since the flag is now enabled by default, there should be no mention of it.
There are still some uses in front_end/testcases that are not just removable
(it also uses `no-non-nullable`). There migth be more uses that are not
as easily found as grepping for `--enable-experiment

Removes two VM tests where fixing them meant they were just duplicating
the corresponding non *_2/ tests.
Fixes #44941

TEST= Large number of tests chaged.=(no-)?non-nullable`.

Change-Id: Ief755981ccde9a5482fcdf408c2929c74433a710
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/183688
Commit-Queue: Lasse R.H. Nielsen <lrn@google.com>
Reviewed-by: Nate Bosch <nbosch@google.com>
2021-02-12 17:16:54 +00:00
Leaf Petersen d44457f79d [Core Libraries] Eliminate the fork in the core libraries.
Move the nnbd core libraries from sdk_nnbd to sdk, and updates
references in build files and elsewhere accordingly.

Change-Id: I09760fe1e006657aacdfe80f3b22fdf6f7e30a9f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/151121
Commit-Queue: Leaf Petersen <leafp@google.com>
Reviewed-by: Bob Nystrom <rnystrom@google.com>
2020-06-16 23:37:36 +00:00
Peter von der Ahé ddf67772bb Remove warning about inferring packages URI from dart2js
Change-Id: I37ee171b0359e1fa6720d7af9e403f4dfab76e9e
Reviewed-on: https://dart-review.googlesource.com/c/79480
Auto-Submit: Peter von der Ahé <ahe@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2018-10-12 07:37:23 +00:00
asiva bc7220a4fd [VM] Turn dart2 on by default on the command line VM
- 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>
2018-06-18 22:31:32 +00:00
Emily Fortuna 483c42b899 Switch dart2js to use dart 2 vm.
Change-Id: I39e807e10f53f647414d4e419b9f3ef3862bd651
Reviewed-on: https://dart-review.googlesource.com/57440
Commit-Queue: Emily Fortuna <efortuna@google.com>
Reviewed-by: Vijay Menon <vsm@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2018-05-31 19:44:36 +00:00
Emily Fortuna e7bad54986 Make dart2js only run with 64 bit ints, not the larger ints from the vm.
Change-Id: I03887a0af963f1a8f68acff0428635fc130687f5
Reviewed-on: https://dart-review.googlesource.com/57041
Commit-Queue: Emily Fortuna <efortuna@google.com>
Reviewed-by: Stephen Adams <sra@google.com>
2018-05-30 17:21:49 +00:00
Sigmund Cherem 0c04eb53c7 Disable int64 when running dart2js
The goal is to renable it as soon as we migrate our constant-evaluator and
constant folding to use Bigint.

Change-Id: I3bba1bbe07517e9cb496896b3417f58173878d62
Reviewed-on: https://dart-review.googlesource.com/34302
Commit-Queue: Sigmund Cherem <sigmund@google.com>
Reviewed-by: Stephen Adams <sra@google.com>
Reviewed-by: Zach Anderson <zra@google.com>
2018-01-16 19:52:22 +00:00
Emily Fortuna 8d8f0c5578 Remove checked mode addition to sdk/bin/dart2js.
BUG=

Review-Url: https://codereview.chromium.org/2608803003 .
2016-12-29 15:46:33 -08:00
Emily Fortuna 9b7247e071 Some constructor quick fixes: implement redirecting constructors, work with finding default constructors (!).
BUG=
R=sigmund@google.com

Review-Url: https://codereview.chromium.org/2607013003 .
2016-12-29 15:43:21 -08:00
William Hesse 9941b665bf Tools not running from snapshots should use /.packages
Stray .package files in their source can otherwise cause errors.

BUG=
R=paulberry@google.com, scheglov@google.com

Review URL: https://codereview.chromium.org/2374453002 .
2016-09-26 18:47:32 +02:00
William Hesse 61eee9ee52 Use checked-in .package file for building and testing
Stop creating [build dir]/packages directory with symbolic links.

BUG=https://github.com/dart-lang/sdk/issues/23565
R=rnystrom@google.com

Committed: 5d3e356ca7

Review URL: https://codereview.chromium.org/1746743002 .

Reverted: 6d238ba197
2016-09-16 15:03:18 +02:00
William Hesse 6d238ba197 Revert "Use checked-in .package file for building and testing"
This reverts commit 5d3e356ca7.

BUG=
R=eernst@google.com

Review URL: https://codereview.chromium.org/2340813004 .
2016-09-15 15:46:49 +02:00
William Hesse 5d3e356ca7 Use checked-in .package file for building and testing
Stop creating [build dir]/packages directory with symbolic links.

BUG=https://github.com/dart-lang/sdk/issues/23565
R=rnystrom@google.com

Review URL: https://codereview.chromium.org/1746743002 .
2016-09-15 14:50:30 +02:00
Paul Berry fadca3983a Change sdk/bin/dart2js to find an available build.
This parallels the change to sdk/bin/dart made by commit
ac8a228d0b.

R=floitsch@google.com

Review URL: https://codereview.chromium.org/1650383002 .
2016-02-01 08:53:13 -08:00
William Hesse 634e5a1d02 Refs #25328 Use a portable shebang
BSD systems don't place bash in /bin and a lot of the dart tools
hardcode a #!/bin/bash shebang that fails the 'all' target build
(not able to execute dart2js since the interpreter is not found).

Solve the issue by using #!/usr/bin/env as the shebang. For scripts
that need to pass arguments to bash modify the script to use the set
command as the first executed line of shell.

BUG=
R=whesse@google.com

Review URL: https://codereview.chromium.org/1552313002 .
2016-01-05 16:26:28 +01:00
Florian Loitsch e9ce747dac Run x64 dart2js version by default.
R=sigmund@google.com

Review URL: https://codereview.chromium.org/1484803003 .
2015-12-01 00:50:53 +01:00
floitsch@google.com 05c54a2ab3 dart2js: Remove heap-growth-flag that was passed to the VM.
R=iposva@google.com

Review URL: https://codereview.chromium.org//892233003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@43441 260f80e4-7a28-3924-810f-c04153c831b5
2015-02-03 22:24:47 +00:00
johnniwinther@google.com 09fbe78e71 Move dart2js from sdk/lib/_internal/compiler to pkg/compiler
BUG=

Review URL: https://codereview.chromium.org//694353007

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@41514 260f80e4-7a28-3924-810f-c04153c831b5
2014-11-05 08:51:01 +00:00
johnniwinther@google.com 8637cfd322 Revert "Move dart2js from sdk/lib/_internal/compiler to pkg/compiler"
This reverts commit r41512.

BUG=

Review URL: https://codereview.chromium.org//693183006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@41513 260f80e4-7a28-3924-810f-c04153c831b5
2014-11-05 08:15:26 +00:00
johnniwinther@google.com 2b336e17f0 Move dart2js from sdk/lib/_internal/compiler to pkg/compiler
BUG=

Review URL: https://codereview.chromium.org//690103004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@41512 260f80e4-7a28-3924-810f-c04153c831b5
2014-11-05 07:09:04 +00:00
nweiz@google.com 326891de60 Support symlinking to dart-sdk executables on Linux and Mac.
R=ahe@google.com, brianwilkerson@google.com, rnystrom@google.com
BUG=9409

Review URL: https://codereview.chromium.org//68503004

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@30287 260f80e4-7a28-3924-810f-c04153c831b5
2013-11-14 19:28:07 +00:00
ricow@google.com c0c636652c Add support for passing in vm options to the dart2js scripts.
R=ahe@google.com

Review URL: https://codereview.chromium.org//23618063

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@27690 260f80e4-7a28-3924-810f-c04153c831b5
2013-09-20 08:25:05 +00:00
ahe@google.com 216289bcb1 dart2js has its own snapshot.
R=ngeoffray@google.com

Review URL: https://codereview.chromium.org//19795006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@25344 260f80e4-7a28-3924-810f-c04153c831b5
2013-07-23 14:58:28 +00:00
kasperl@google.com 679b8760a6 Reland "Add --version option to dart2js and add version information (if available) to generated code."
R=ahe@google.com
BUG=

Review URL: https://codereview.chromium.org//16114013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23378 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-30 05:49:28 +00:00
kasperl@google.com e90972e3e0 Revert "Add --version option to dart2js and add version information (if available) to generated code."
This reverts commit f67288738b5184572db13b35ff5f84438e03e907.

R=ahe@google.com
BUG=

Review URL: https://codereview.chromium.org//15915013

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23356 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-29 17:33:32 +00:00
kasperl@google.com 3c95824799 Add --version option to dart2js and add version information (if available) to generated code.
Remove the 'Using snapshot ...' comment from sdk/bin/dart2js since we are
now relatively sure it works.

R=ahe@google.com, ngeoffray@google.com
BUG=http://dartbug.com/4439, http://dartbug.com/9848

Review URL: https://codereview.chromium.org//15957006

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@23355 260f80e4-7a28-3924-810f-c04153c831b5
2013-05-29 17:01:09 +00:00
ricow@google.com 00da866b33 Move the dart2js snapshot into bin directory of sdk root.
This is the first step in eliminating lib/_internal.
Review URL: https://codereview.chromium.org//13945008

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@21247 260f80e4-7a28-3924-810f-c04153c831b5
2013-04-11 05:47:24 +00:00
asiva@google.com 5858afd74a Write the magic number 0xf5f5dcdc into a script snapshot file and use this to distinguish whether a script snapshot or a regular script file is being passed on the command line (removed the --use-script-snapshot option).
Review URL: https://codereview.chromium.org//12438033

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@20339 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-21 18:47:49 +00:00
iposva@google.com e8ade81cf7 - Remove the --no-use-inlining flag as it is not beneficial as the compiled programs grow.
Review URL: https://codereview.chromium.org//12386030

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@19559 260f80e4-7a28-3924-810f-c04153c831b5
2013-03-06 14:44:18 +00:00
asiva@google.com d313a1243f 1. Change option --use_script_snapshot to --use-script-snapshot (easier to type).
2. Use dart binary with the --generate-script-snapshot option to generate dart2js snapshot
Review URL: https://codereview.chromium.org//12084010

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@17686 260f80e4-7a28-3924-810f-c04153c831b5
2013-01-26 05:47:56 +00:00
ahe@google.com d45a3d0d69 Correct snapshot location and fix a dependency problem.
Review URL: https://codereview.chromium.org//11411260

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15519 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-29 14:49:44 +00:00
ahe@google.com c17990a886 Call dart2js directly from sdk/bin.
Review URL: https://codereview.chromium.org//11299206

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@15512 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-29 12:15:29 +00:00
dgrove@google.com 65db39f5cf Create wrappers for MacOS/Linux to allow sdk "binaries" to be
run from the repo.
Review URL: https://codereview.chromium.org//11381003

git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@14764 260f80e4-7a28-3924-810f-c04153c831b5
2012-11-09 23:04:42 +00:00