Commit Graph

1931 Commits

Author SHA1 Message Date
John Messerly a260ce7a62 fixes #69, avoid module name inside module scope
R=vsm@google.com

Review URL: https://codereview.chromium.org/967713002
2015-03-02 07:10:55 -08:00
Sigmund Cherem a72f8d67b9 Fix report test
Review URL: https://codereview.chromium.org/965033003
2015-02-27 17:39:03 -08:00
Sigmund Cherem 212bb2af11 Fix reporter
R=vsm@google.com

Review URL: https://codereview.chromium.org/968483002
2015-02-27 15:36:34 -08:00
John Messerly 4d7aa8e397 add source maps support, fixes #50
R=sigmund@google.com

Review URL: https://codereview.chromium.org/965033002
2015-02-27 15:17:19 -08:00
John Messerly bd06d9e7f4 support the JS builtin
* fix a few cases where we regressed js_ast parser interpolations
* infer correct static type for JS call expressions

R=vsm@google.com

Review URL: https://codereview.chromium.org/962083002
2015-02-27 11:28:41 -08:00
Vijay Menon 6859e76565 DDC fixes on DDC
This isn't everything by far, but most issues local to DDC itself that
we mark error right now.  There are a bunch of down casts around
literals and not-quite-generic methods.

R=leafp@google.com

Review URL: https://codereview.chromium.org/963063003
2015-02-27 10:16:14 -08:00
John Messerly 2a5adfe05a fix analysis messages
seen on the latest dev channel editor w/ analysis server

R=sigmund@google.com

Review URL: https://codereview.chromium.org/962213003
2015-02-27 09:06:13 -08:00
John Messerly a3bbe2a291 cleans up sdk patching so we no longer have unresolved names
js_codegen.dart and patch_sdk.dart are the only human-changed files.

This also pulls in dart:isolate, which is depended on from one of the implementation libraries

This also moves dart:_* files back to `lib/_internal/compiler/js_lib/` because there's where libraries.dart points to, and hence Analyzer looks for them there. Alternatively, we could put them somewhere like `tool/input_sdk_internal` and then copy that file into the right path.

R=vsm@google.com

Review URL: https://codereview.chromium.org/955513008
2015-02-26 17:58:13 -08:00
Leaf Petersen 40688929e5 Typecheck map and list literals
We were not checking the elements of list and map literals against the declared type of the literal.

BUG=
R=vsm@google.com

Review URL: https://codereview.chromium.org/957013002
2015-02-26 16:45:15 -08:00
Vijay Menon 50753e3a47 Typecheck constructor initializers properly
R=leafp@google.com

Review URL: https://codereview.chromium.org/959003003
2015-02-26 16:19:27 -08:00
Sigmund Cherem 9369b3e981 Fix new line breaks on }
R=leafp@google.com

Review URL: https://codereview.chromium.org/959073002
2015-02-26 14:32:48 -08:00
Sigmund Cherem 2ffd89471a Disable formatting and add new-lines to make tests faster.
R=vsm@google.com

Review URL: https://codereview.chromium.org/963593002
2015-02-26 13:13:56 -08:00
John Messerly ead4fe2e85 merge class extensions from patch files.
There are a few examples of classes like this:

```dart
@patch
class StringBuffer {
  ... various @patch members ...
  // no @patch here
  void _writeString(str) { ... }
}
```

we need to merge in those members too

R=vsm@google.com

Review URL: https://codereview.chromium.org/955513007
2015-02-26 08:08:21 -08:00
John Messerly 425c3d8359 don't run dart gen on JS patch code
R=vsm@google.com

Review URL: https://codereview.chromium.org/961493003
2015-02-26 08:07:22 -08:00
Sigmund Cherem 9b00a0ecd2 Move argument parsing also to the options.dart file, adds fields for flags we were not storing in the CompilerOptions object.
R=vsm@google.com

Review URL: https://codereview.chromium.org/961503002
2015-02-25 16:40:20 -08:00
John Messerly 89651ccdef cleanup patch generation to preseve comments and remove @patch
the only human authored changes here are tool/patch_sdk.dart

R=vsm@google.com

Review URL: https://codereview.chromium.org/959913003
2015-02-25 13:23:23 -08:00
John Messerly b82e83f383 use js_ast instead of strings to generate JS
fixes https://github.com/dart-lang/dev_compiler/issues/61

R=sigmund@google.com, vsm@google.com

Review URL: https://codereview.chromium.org/949383003
2015-02-25 11:14:19 -08:00
John Messerly 8fac687185 Update README.md
fix name
2015-02-25 07:38:52 -08:00
Sigmund Cherem e57c960817 rename package:ddc to package:dev_compiler
BUG=
R=vsm@google.com

Review URL: https://codereview.chromium.org/954773003
2015-02-24 17:01:15 -08:00
vsmenon 8cb4a6f016 Update codereview.settings 2015-02-24 16:57:57 -08:00
John Messerly 0e46bb35ba fix formatting to include test, exclude lib/src/js
R=sigmund@google.com

Review URL: https://codereview.chromium.org/953093005
2015-02-24 16:56:13 -08:00
Vijay Menon 5c1c9c2381 Add LICENSE and corresponding headers
Fix expectations where line number has changed.

R=dgrove@google.com

Review URL: https://chromereviews.googleplex.com/158257013
2015-02-24 15:02:26 -08:00
Vijay Menon e22ce4ce4c Point to new list and rietveld
BUG=
R=dgrove@google.com

Review URL: https://codereview.chromium.org/943043003
2015-02-24 14:32:38 -08:00
Sigmund Cherem e06c30a76f Fix pubspec to resolve conflict with dart_style analyzer dependency 2015-02-24 10:10:01 -08:00
Sigmund Cherem 6ca4479a85 Undo rename of analyzer now that we are unforked
BUG=

Review URL: https://chromereviews.googleplex.com/158907014
2015-02-24 10:06:47 -08:00
vsmenon 0bccf25a0d Merge pull request #65 from dart-lang/readme
add README
2015-02-24 09:56:17 -08:00
Dan Grove bdc086d40d Update wording. 2015-02-24 09:01:22 -08:00
John Messerly 7dbb2c44ef Add js_ast package at lib/src/js
This is a clean copy so it will be easier to review my changes for ES6. This is r43816 from SVN pkg/compiler/lib/src/js, with dart2js internal files removed (js.dart, rewrite_async.dart)

As with analyzer, we'll have a fork so we can iterate faster. But we'll upstream the changes.

R=sigmund@google.com

Review URL: https://chromereviews.googleplex.com/160777013
2015-02-24 08:41:14 -08:00
Vijay Menon ee887b1ed9 Flag to ignore types during codegen
R=jmesserly@google.com, leafp@google.com

Review URL: https://chromereviews.googleplex.com/161647013
2015-02-20 17:06:01 -08:00
Sigmund Cherem 608906db87 Fixes needed so we work correctly with the latest analyzer
Review URL: https://chromereviews.googleplex.com/157367013
2015-02-20 15:39:28 -08:00
Vijay Menon ddce235e3d Set nonnullable types by flag
R=sigmund@google.com

Review URL: https://chromereviews.googleplex.com/156397013
2015-02-20 14:34:44 -08:00
Sigmund Cherem d2834b49a6 Reenable type promotion
R=jmesserly@google.com, vsm@google.com

Review URL: https://chromereviews.googleplex.com/159667013
2015-02-20 13:56:46 -08:00
Sigmund Cherem 1a83c63a08 Small changes to reduce modifications in analyzer
R=vsm@google.com

Review URL: https://chromereviews.googleplex.com/160677013
2015-02-20 13:48:14 -08:00
Dan Grove 67eb4858b3 add README 2015-02-20 11:33:51 -08:00
John Messerly 6c7cd9b731 Begin to handle some of the *_patch.dart files
Moves: test/sdk --> tool/input_sdk_src
Also moves: test/sdk/lib/_internal/js_lib --> tool/input_sdk_patch
we'll eventually need to customize that code

Adds tool/patch_sdk.dart, an offline transformation step that produces: test/generated_sdk

Essentially this merges the "external" declarations and the @patch syntactically. There's a comment in tool/patch_sdk.dart explaining the rationale behind this approach.

There's still *lots* to do in the generated code. This does none of that. The only new code is tool/patch_sdk.dart and the minimum changes to test/codegen_test.dart and js_codegen.dart to get test.sh running and debuggable.

Tracking bug for SDK is https://github.com/dart-lang/dart-dev-compiler/issues/58

R=sigmund@google.com, vsm@google.com

Review URL: https://chromereviews.googleplex.com/157137013
2015-02-20 08:58:01 -08:00
Sigmund Cherem c1f84cfada Add more flags, fix missing initialization of a couple flags
BUG=
R=vsm@google.com

Review URL: https://chromereviews.googleplex.com/150577015
2015-02-19 16:13:21 -08:00
John Messerly 0ddedfb3da fix incorrect DartObject reference
Review URL: https://chromereviews.googleplex.com/156337013
2015-02-19 09:32:21 -08:00
Vijay Menon 7bb76996ea Fix maybe nullable check when no nonnullable types
R=leafp@google.com

Review URL: https://chromereviews.googleplex.com/154527013
2015-02-19 08:57:27 -08:00
Sigmund Cherem d78ecd3241 Infer consts and final fields based on RHS
R=vsm@google.com

Review URL: https://chromereviews.googleplex.com/142457013
2015-02-19 08:34:01 -08:00
Sigmund Cherem 34fd717c0a Minor changes to fix up edit_files, which broke when we moved the multi-package
options from -D to flags.

BUG=
R=jmesserly@google.com

Review URL: https://chromereviews.googleplex.com/151567013
2015-02-19 08:28:55 -08:00
Sigmund Cherem ce3dd48740 Accept compilng HTML files
R=jmesserly@google.com, vsm@google.com

Review URL: https://chromereviews.googleplex.com/153157013
2015-02-18 16:48:56 -08:00
John Messerly 7c1ab1f04d work around issue #51, super restrictions in V8
Adds an explicit "extends dart.Object", which we probably want for other reasons (e.g. toString, runtimeType, hashCode)

Attempts to recover some readability by tweaking the name of the initialize functions. This closes #51, but we should open another tracking bug because there are concerning aspects to this workaround.

R=sigmund@google.com, vsm@google.com

Review URL: https://chromereviews.googleplex.com/150417015
2015-02-18 16:27:32 -08:00
Vijay Menon 260cfc05d2 Make nonnullability configurable
John: I added code in the JS codegen to query which primitives are non-nullable.

R=jmesserly@google.com, sigmund@google.com

Review URL: https://chromereviews.googleplex.com/155407013
2015-02-18 14:20:22 -08:00
Vijay Menon eb3c51e6f3 Check default parameters properly
R=leafp@google.com

Review URL: https://chromereviews.googleplex.com/155367013
2015-02-18 12:13:30 -08:00
Sigmund Cherem b23578984b Unify naming of output libraries in both backends
R=jmesserly@google.com, leafp@google.com

Review URL: https://chromereviews.googleplex.com/157197015
2015-02-18 10:12:54 -08:00
John Messerly 694c93c61f fix #41, named arguments with conversions
R=leafp@google.com

Review URL: https://chromereviews.googleplex.com/150407013
2015-02-17 13:27:37 -08:00
Sigmund Cherem ae910f2860 Infer return types and field types based on overrides
R=jmesserly@google.com, vsm@google.com

Review URL: https://chromereviews.googleplex.com/145247013
2015-02-13 16:53:58 -08:00
Sigmund Cherem 46dfefcae7 Fix check of functions agasint void.
R=vsm@google.com

Review URL: https://chromereviews.googleplex.com/156137013
2015-02-13 16:48:37 -08:00
Sigmund Cherem 0ab8340e79 Minor improvement on dart:mocks mocks, and fix related test.
R=jmesserly@google.com

Review URL: https://chromereviews.googleplex.com/155267013
2015-02-13 16:18:36 -08:00
Sigmund Cherem c08003a36e Add options and move the multi-package options to normal flags
R=jmesserly@google.com

Review URL: https://chromereviews.googleplex.com/149487013
2015-02-13 13:04:16 -08:00