Find a file
Jenny Messerly 472c898c87 [dartdevc] fix for-in loop variable shadowing a var used in initialzer
Dart for-in loops allow `var x = [1]; for (var x in x) {}`, which is not
allowed in JS. If this pattern is detected, a temporary variable is
introduced so the for-in initializer expression is evaluated outside of
the JS for-of loop.

(This issue seems to be unique to for-in loops. For loops and other
kinds of variable declarations of the form `var x = ...` are not
allowed to use `x` in the initializer, even if `x` is declared in an
outer scope.)

Also fixes an out-of-date comment in the DDC+Analyzer backend.

Change-Id: I35b272a5a311f7b6f104cc82a99cc83a6ed5c247
Reviewed-on: https://dart-review.googlesource.com/c/79142
Commit-Queue: Alan Knight <alanknight@google.com>
Auto-Submit: Jenny Messerly <jmesserly@google.com>
Reviewed-by: Alan Knight <alanknight@google.com>
2018-10-11 17:07:39 +00:00
.github Add no-response bot configuration. 2018-10-05 22:21:06 +00:00
build Fix build rule. 2018-10-03 20:25:36 +00:00
client
docs Add initial version of feature specification on interface conflicts. 2018-10-11 13:32:00 +00:00
pkg [dartdevc] fix for-in loop variable shadowing a var used in initialzer 2018-10-11 17:07:39 +00:00
runtime [gardening] Fix leaks in run_vm_tests binary detected by ASAN. 2018-10-11 16:52:14 +00:00
samples [vm] Remove script snapshots. 2018-09-26 22:49:27 +00:00
samples-dev fix some typos 2018-10-10 19:15:30 +00:00
sdk Report null error as a NoSuchMethodError 2018-10-10 20:07:44 +00:00
tests [dartdevc] fix for-in loop variable shadowing a var used in initialzer 2018-10-11 17:07:39 +00:00
third_party Revert "[infra] Upgrade gsutil to a new version (#31065)" 2018-10-11 13:00:12 +00:00
tools [gardening] Fix leaks in run_vm_tests binary detected by ASAN. 2018-10-11 16:52:14 +00:00
utils Remove TargetFlags.strongMode 2018-10-10 12:11:41 +00:00
.clang-format
.gitattributes Force lf-lineendings for .dart-files. 2018-10-02 19:44:04 +00:00
.gitconfig [infra] Add documentation to .gitconfig 2018-06-11 18:24:16 +00:00
.gitignore
.gn
.mailmap fix my name in .mailmap 2018-09-11 01:45:52 +00:00
.packages Upgrade dartdoc and dependencies for 0.22.0. 2018-10-03 21:05:17 +00:00
.vpython [infra] Add .vpython spec to fix gsutil on the bots (#31065) 2018-10-11 15:11:35 +00:00
AUTHORS
BUILD.gn [VM] Remove 'corelib' and 'dart-io' sources generation into C++ arrays 2018-10-02 23:27:05 +00:00
CHANGELOG.md [release] Prepare changelog for 2.1.0-dev.7.0 2018-10-10 18:36:42 +00:00
codereview.settings Update codereview.settings to Gerrit (dart-review.googlesource.com) 2017-09-04 12:52:09 +00:00
CONTRIBUTING.md Add CONTRIBUTING.md 2018-08-15 18:02:17 +00:00
dartdoc_options.yaml Add a 'Core' category for doc generation. 2018-06-07 14:47:41 +00:00
DEPS Revert "[infra] Upgrade gsutil to a new version (#31065)" 2018-10-11 13:00:12 +00:00
LICENSE
PATENTS
PRESUBMIT.py Fix presubmit on Windows. Dart executable is not called .bat 2018-05-02 08:40:59 +00:00
README.dart-sdk
README.md
WATCHLISTS CC sra also in changes to compiler files and tests 2018-07-31 18:27:19 +00:00

Dart

Dart is an open-source, scalable programming language, with robust libraries and runtimes, for building web, server, and mobile apps.

Using Dart

Visit the dartlang.org to learn more about the language, tools, getting started, and more.

Browse pub.dartlang.org for more packages and libraries contributed by the community and the Dart team.

Building Dart

If you want to build Dart yourself, here is a guide to getting the source, preparing your machine to build the SDK, and building.

There are more documents on our wiki.

Contributing to Dart

The easiest way to contribute to Dart is to file issues.

You can also contribute patches, as described in Contributing.

License & patents

See LICENSE and PATENTS.