Commit Graph

45 Commits

Author SHA1 Message Date
Jens Johansen 153683b1be [cfe] Get rid of 'strong' in incremental compiler tests
Fixes #37302.

Change-Id: Id8e83dfa86dcd188e5541e0465fab08a51e39882
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/106900
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-06-21 09:53:36 +00:00
Jens Johansen 43937aa9ca Don't let expression compilation bleed into real library
If an expression compilation issues problems of any sort, they are saved
in the target-libraries problemsAsJson field. That's not ideal,
as it means that they can be re-issued later, as well as possibly being
serialized into the dill file.

This CL resets the problemsAsJson field of the real library,
thus fixing the issue.

Change-Id: I765c2cc50059c6bcda6a56bb749869dd4b181876
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/96800
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
2019-04-30 11:38:48 +00:00
Jens Johansen 054d1a301c Another test for reissuing problems
Test that we don't reissue problems for unreferenced libraries.

Change-Id: I5cf223ead48d2cd1dac293899495a46f92f4a495
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/96785
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
2019-04-30 11:05:53 +00:00
Jens Johansen ed8e4255a4 Proposed fix to #36644
TL;DR: Unbind canonical names doesn't do what you think it does and
probably shouldn't (ever) be used. This CL stops using it in a few places.

Longer version:

When loading a dill file it:
- First loads the table of canonical names. These have no references yet.
- When a canonical name is asked for its reference it creates one if it
  doesn't yet have one.
- When loading, for instance, a library, it asks for the reference.

When unbinding a canonical name:
- It removes itself (the canonical name) from the reference
- It removes the reference in itself
- Note: Whatever has a pointer to the reference keeps it, and the
  reference points to whatever node it already pointed to.

This also means, that if we have a dill file that's split in two and:
- Load #1
- Load #2
that works fine, but if we
- Load #1
- Unbind canonical names
- Binds canonical names
- Load #2
stuff is not bound correctly (and an error is thrown).

And - the cause of this bug:
- Load #1
- Load #2
everything is fine
- Unbind canonical names
- Binds canonical names
- Load #2'
stuff is not bound correctly --- references points to stuff loaded as #2,
not as #2'. On top of being weird, wrong and confusing it also caused wrong
things to be but into the class hierarchy which ultimatly caused the crash.

This CL fixes it by not calling unbind and force loading of dill files
(at specific call sites) to create new libraries
(and in the process overwriting references ".node").

Revert "[dartdevc] Retry ddc incremental compile on crash"

This reverts commit ecdbdf00b8.

Revert "[kernel_worker] retry on failure"

This reverts commit 43eebea5a3.

Fixes #36644

Bug: #36644
Change-Id: Id8f548179e6a409b01f2ebfa3219f94cb64b1c05
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/100380
Reviewed-by: Kevin Millikin <kmillikin@google.com>
Reviewed-by: Vijay Menon <vsm@google.com>
Reviewed-by: Jake Macdonald <jakemac@google.com>
Reviewed-by: Jenny Messerly <jmesserly@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-04-26 07:18:28 +00:00
Kevin Millikin e42a8032fb [cfe] Remove uninferred initializers from outlines
When performing top-level type inference based on overrides for fields
that have initializers, we never perform type inference for the
initializers.  Since type inference is the thing that rewrites shadow
AST nodes with their Kernel translation, we are left with
untransformed shadow nodes that cannot be serialized.

Instead, remove these initializers.  Fixes
https://github.com/dart-lang/sdk/issues/36498

Change-Id: I044fadd897e9f2d0e37f5ce0e5adaadb0e42a992
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/99120
Commit-Queue: Dmitry Stefantsov <dmitryas@google.com>
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2019-04-15 16:17:35 +00:00
Jens Johansen 4fe2f6f349 Add more tests to the incremental compiler
Add a test that reproduces a error we had in flutter code when
for instance 51da94da76 was HEAD.

Add a test for constant sets.

Change-Id: Ibae4891623bb23b93473aae6b29387cfcb66bf3a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/98340
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-03-29 12:20:12 +00:00
Jens Johansen a977273262 Re-allow the incremental compiler to load modules
This reverts commit 4d43abdd9f2f3026ccfabaa5495499b3ea220430 and adds a
fix.

Change-Id: Id80186aba02dd80171aac3843d63aa4f42c5ca17
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/98017
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-03-28 12:53:01 +00:00
Jens Johansen cf768254fd Temporarily disable 'Allow the incremental compiler to load modules'
Caused weird test failures. Disabling while investigating.

Change-Id: I566a209175a1ad6a4384ee815f54ba04bdb75570
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/98120
Reviewed-by: Jens Johansen <jensj@google.com>
2019-03-28 09:59:29 +00:00
Jens Johansen 32a5fa0a83 Allow incremental compiler to just create outline
Change-Id: I996787821f01f21bb41be837e6d4c25a2114e017
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/95384
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2019-03-28 08:44:56 +00:00
Jens Johansen 83e6e9f8e6 Allow the incremental compiler to load modules
Change-Id: I63bbbdfc94ac6ab0b7b8cce104fe38c4ba592f34
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/95382
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2019-03-28 08:39:41 +00:00
Jens Johansen eb344e2072 Keep live libraries and uri to source in sync
This CL removes the sources from uriToSource for libraries
the incremental compiler doesn't keep around.

This includes:
* Explicitly invalidated libraries, also if in a package.
* Transitively invalidated libraries, also if in a package.
* Libraries that are now no longer referenced in the resulting whole
  program, unless it's in a package.
* Libraries from packages that are implicitly invalidated by an
  updated .packages file (e.g. if the .packages file no longer
  reference it or reference a new version of it).

This does *NOT* include:
* Libraries from packages that are not invalidated and that are still
  mentioned in .packages, even if the actual libraries are no longer
  referenced in the resulting whole program. The reason is that these
  libraries are kept around in the incremental compiler.

Bug: 36197
Change-Id: I0ed41567ab54828585326ffd4dcb3722980bf874
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97201
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-03-21 10:08:30 +00:00
Jens Johansen 1a88421d39 Allow to change .package uri in incremental compiler
Change-Id: Ic36fd000e2a3ea2870460b68821c7404f6e62a1a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/95140
Reviewed-by: Peter von der Ahé <ahe@google.com>
2019-03-05 07:39:31 +00:00
Jens Johansen 2695cdfbb1 Change incremental compiler to take entry points (plural)
Change-Id: I03203cdeb11ab7bc6116779642909ebc7220c619
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/95122
Reviewed-by: Peter von der Ahé <ahe@google.com>
2019-03-05 07:39:31 +00:00
Jens Johansen 2087d6db46 initializeFromComponent has to include platform
For initializeFromComponent to work correctly the platform has to be
provided (as the other libraries provided are linked to some platform,
and loading another one is thus no good).
This CL changes it so we don't load another one, and checks that the
component we're trying to initialize from actually contains dart:core.

Change-Id: I88d30436c101c589b0555ff70ae21297ed665d7b
Reviewed-on: https://dart-review.googlesource.com/c/93435
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
2019-02-22 13:08:45 +00:00
Jens Johansen e4d1b28698 Incremental compiler should respect omitPlatform setting
Change-Id: Id842db646ba95945c8fadce0626cb8cbee2812ad
Reviewed-on: https://dart-review.googlesource.com/c/93433
Reviewed-by: Peter von der Ahé <ahe@google.com>
Reviewed-by: Alexander Aprelev <aam@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-02-22 11:44:45 +00:00
Jens Johansen 3196b87f10 Incremental compiler: Include right libraries when entry point is translated
Without this CL the incremental compiler could potentially return too
few libraries (or possibly 0 libraries):

If the entry point is translated to a package-URI and there is no main,
the entry-library when doing the transitive closure cannot be found and the
output will be no libraries.

If the entry point is translated to a package-URI and there is a main,
the entry-library when doing the transitive clusire is only found because
of the otherwise unneeded `mainMethod` parametesr.

This CL adds tests and fixes the problem.

Change-Id: Icea72eb892cb0d16f0d86e3729e29ce026fa7073
Reviewed-on: https://dart-review.googlesource.com/c/92430
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2019-02-13 13:26:37 +00:00
Jens Johansen d9072d5272 Re-issue all problems in the incremental compiler
Prior to this change, old problems (warnings, errors, etc) would not be
re-issued for files not actually recompiled when recompiling.

As an example, not making any change and recompiling it would seem like
everything was good.

With this change, all problems should be issued again.

Change-Id: Ia410edba27438d8a2f1842d9f4d81d0592571101
Reviewed-on: https://dart-review.googlesource.com/c/91747
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2019-02-01 12:49:57 +00:00
Jens Johansen eb956a2516 Add synthetic bit to Library flags
Fasta can generate synthetic libraries.
Previously we didn't include them when serializing, but that leaves
references in the binary to libraries that doesn't exist which isn't
ideal.

This change includes them, and adds a flag to kernel Libraries such that
we know they are synthetic.

Change-Id: Ied25a21cd1f384d318347021bc7ec18dae3a4e05
Reviewed-on: https://dart-review.googlesource.com/c/91722
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2019-02-01 11:00:26 +00:00
Jens Johansen e9597684fe Fix for incremental compiler swallowing certain errors
Prior to this change, problems issued in hierarchy.mixinInferrer could
be swallowed up because it was reported through a wrong loader that
had already issued the error.

Change-Id: Iecbc180ca8a0bfaa73db202e4cba9755812d1e3b
Reviewed-on: https://dart-review.googlesource.com/c/91746
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2019-02-01 10:59:26 +00:00
Jens Johansen 42be4083bd Reproduction of dartbug.com/35715
Get an error saying something like
"The argument type 'dart.core::String' can't be assigned to
the parameter type 'dart.core::String'"

Change-Id: I327c613a2070495653e4089475a4f3edf550e9d4
Reviewed-on: https://dart-review.googlesource.com/c/91228
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2019-01-28 12:15:41 +00:00
Jens Johansen 1ec63ec7d5 Only one source of truth for uriToSource
Previously we had several places where different uriToSource was used.
This was both weird and led to errors when something refering to
some state was used to look up in another state.
This CL makes it so we only have one source of truth.

To not include sdk sources when serializing a component that only mixes
something from the sdk in, (or extends it or...), the serialization is
changed slightly to keep track of which uris come from actual
implementation. Before the sdk sources was explicitly removed in the
incremental compiler, but we want to limit those kinds of things,
which is why we're doing it differently here.

Fixes #35215.

Bug: 35215
Change-Id: Iaa5618fcb0ea42b13aba7720f34a87a85144e047
Reviewed-on: https://dart-review.googlesource.com/c/85175
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2018-11-28 10:57:01 +00:00
Jens Johansen 89936a2a0f Fix invalidating part specified via package uri via file uri
In the incremental compiler, if asking to invalidate a file via a file
uri, where the corresponding file is a part that has been used via its
package uri (as in "part 'package:foo/whatever.dart'"), we should still
invalidate it.

Before we didn't because we 'translated' the part uri to a 'file uri'
except it was still a package uri.
Now we do.

Change-Id: I276c6e7c772d6167178fa8b6594417d37d1dd1c4
Reviewed-on: https://dart-review.googlesource.com/c/85344
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-11-28 10:53:21 +00:00
Peter von der Ahé 935af1e77f Use unique package paths in incremental_load_from_dill_test.dart
Change-Id: I94cb9ddffa604bdb682af0da0df4810b7523954d
Reviewed-on: https://dart-review.googlesource.com/c/78462
Auto-Submit: Peter von der Ahé <ahe@google.com>
Reviewed-by: Jens Johansen <jensj@google.com>
2018-10-08 10:09:25 +00:00
Kevin Millikin c9b05d3f1f Allow super calls in mixin declarations
Allow super calls to occur in mixin declarations if they target a
method from any of the superclass constraint interfaces.

Instead of compiling the Dart mixin declaration
    mixin M on S0, S1 {...}
to Kernel:
    abstract class _M&S0&S1 = S0 with S1;
    abstract class M extends _M&S0&S1 { ... }
we compile it to Kernel:
    abstract class _M&S0&S1 implements S0, S1 {}
    abstract class M extends _M&S0&S1 { ... }
because the former is not symmetrical with respect to S0 and S1.  It
will prefer a method from the 'mixin' S1 over one from S0 which can
give a compile-time error if the method from S0 is more general.

Modify mixin inference to support the new compilation of mixin
declarations.  It still has to support old-style VM super mixins until
support for those is removed from the VM.

Change-Id: Ib945aa11cc19c457b07bc802beae10d1663ff6b7
Reviewed-on: https://dart-review.googlesource.com/76141
Reviewed-by: Jenny Messerly <jmesserly@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Kevin Millikin <kmillikin@google.com>
2018-09-27 10:19:30 +00:00
Peter von der Ahé 56c2ed5e9e Avoid deprecation in source_loader
Change-Id: Idf3250bd8fcc56f7d52e3f245671d2c1b91d0956
Reviewed-on: https://dart-review.googlesource.com/63144
Reviewed-by: Aske Simon Christensen <askesc@google.com>
2018-09-13 08:10:15 +00:00
Kevin Millikin 6e63df3bfb Revert "Avoid the deprecated input error in source_loader"
Reverted because of failures on the VM reload tests.

Change-Id: I880523a5f3e14cc6d318d4493f037b79515b1dce
Reviewed-on: https://dart-review.googlesource.com/71401
Reviewed-by: Kevin Millikin <kmillikin@google.com>
Commit-Queue: Kevin Millikin <kmillikin@google.com>
2018-08-24 11:03:28 +00:00
Kevin Millikin 0eb0f700b8 Avoid the deprecated input error in source_loader
Avoid using deprecated errors by hadling them on a case-by-case basis.
This is a version of https://dart-review.googlesource.com/c/sdk/+/63144
with merge conflicts resolved.

Fixes #33686

Change-Id: I726740af2db5d32f15c8103c903376bc8ea948e6
Reviewed-on: https://dart-review.googlesource.com/71161
Reviewed-by: Kevin Millikin <kmillikin@google.com>
Commit-Queue: Kevin Millikin <kmillikin@google.com>
2018-08-24 09:14:15 +00:00
Jens Johansen 57d48dcc9f Fix bug in incremental compiler, only later using initialized type
Before this CL, if initializing from a dill file containing a class,
say A, but it wasn't used, and then later using it as a type, say
'A a = new A()', the class hierarchy would complain about not knowing A.

This was caused by the class hierarchy initially being constructed using
the full component of the first compile (i.e. in the example above
without any usage of A and thus without including A), and subsequent
compiles telling the class hierarchy about new classes created in that
compile. The problem was, that if the class was loaded from a dill file
(in the example above 'A' was such a class) it would never be included
if not a part of the first full component.

This CL fixes it by changing the interface to the class hierarchys
`applyTreeChanges` function and letting the class hierarchy know about
libraries too: It will now basically just be given the full component
when asked to update, and just update with the libraries it doesn't
already know about. In the example above that would - once using 'A' -
include 'A'.

Change-Id: I895100b51659938636da0bca6c80516d87b57a24
Reviewed-on: https://dart-review.googlesource.com/69302
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2018-08-16 13:26:08 +00:00
Jens Johansen fd26343f98 Fix invalidation not sticking on compile error
Before this CL, the invalidated URLs would be cleared sooner than we
threw away the old "userCode".
On a compile time error (issuing an erroneousComponent) we restore
the old userCode, thus in practical terms forgetting about whatever
had been invalidated prior to that.

This CL introduces a test and fixes the problem.

Change-Id: I8f5329c2f499ec3842d0b7d67e2eda1de1e7d938
Reviewed-on: https://dart-review.googlesource.com/52321
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Aske Simon Christensen <askesc@google.com>
2018-05-15 14:25:16 +00:00
Kevin Millikin 8dbe716085 Remove the unused GenericCovariantInterface bit
None of the back ends are using it and it imposes a cost to have to
compute it and try to preserve it.

Change-Id: I217e1191b535829021fa11f2698cadd8d4baf1c8
Reviewed-on: https://dart-review.googlesource.com/54383
Commit-Queue: Kevin Millikin <kmillikin@google.com>
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2018-05-09 15:04:43 +00:00
Dmitry Stefantsov 4f586e265e [fasta] Update expectation files after CL 50941
Change-Id: I85aba2501a7b8a911e122f0a802dfc21b7e87e1e
Reviewed-on: https://dart-review.googlesource.com/51620
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Dmitry Stefantsov <dmitryas@google.com>
2018-05-08 10:53:47 +00:00
Jens Johansen 16696ca9d5 Cleanup in incremental compiler test
Address comments from https://dart-review.googlesource.com/c/sdk/+/49642.

Change-Id: I80bc2f851d5f65b81d9e44e2c412f2b0b2d208c2
Reviewed-on: https://dart-review.googlesource.com/50200
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-04-17 09:39:46 +00:00
Jens Johansen df6055d876 Only bypass cache when .packages is invalidated
In a86b864fa9 the incremental compiler was
updated to always bypass the cache when getting a UrlTranslator to be
able to handle the case where .packages had been updated.

This was driven by Flutter not invalidating .packages.

This has now been introduced in flutter with
https://github.com/flutter/flutter/pull/16467
and we can now limit when we bypass the cache to when the .packages file
has been invalidated.

This CL does just that, and further more adds tests where .packages either
appears or disappears.

Change-Id: I3e2d001a993a59c115bc00fcf714f97094357d35
Reviewed-on: https://dart-review.googlesource.com/50940
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-04-12 11:40:44 +00:00
Jens Johansen 5aec8ad6fb Delete invalidated builder loaded from dill
Prior to this CL a builder loaded from a dill file - but where the
file has now been deleted (and we've previously been told about it) -
was kept around, meaning that it could get resurrected in a later
call to computeDelta.

This CL introduces a test and fixes the problem.

Change-Id: Ia18639a1387b37f8d641f803f202288dd185af5c
Reviewed-on: https://dart-review.googlesource.com/50722
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2018-04-12 10:27:24 +00:00
Jens Johansen e6962790a1 Use import URIs when invalidating files
Fixes https://github.com/flutter/flutter/issues/16368
Note that this is mostly a copy of
https://dart-review.googlesource.com/c/sdk/+/48180

Change-Id: Ibdf7719d8b362a4c179fd7a4a6ab5ae7028a5429
Reviewed-on: https://dart-review.googlesource.com/50420
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-04-10 13:52:42 +00:00
Jens Johansen a86b864fa9 Handle updated .packages in incremental compiler
Change-Id: I6de6cb643b14b14ce54944f57b9e15f502750206
Reviewed-on: https://dart-review.googlesource.com/49901
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2018-04-10 10:57:31 +00:00
Jens Johansen b2d7749643 Fix issue with missing sources
Before this CL, if initializing from a dill file, and then,
at a subsequent call to computeDelta asks for the full Component,
the sources from the originally loaded libraries was missing.
This also meant that some fileUris were missing.

This can basically break Flutter.

This CL introduces tests that catch this, fixes the issue and bumps the
kernel version to force recompilation in Flutter.

Change-Id: I9f62962db017cec232855377835103ffc324820b
Reviewed-on: https://dart-review.googlesource.com/49642
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2018-04-05 13:23:07 +00:00
Siva Annamalai 2676c132cb Revert "Cleanup in incremental compiler"
This reverts commit 5367304ba5.

Reason for revert: Please see issue 32776
https://github.com/dart-lang/sdk/issues/32776

Original change's description:
> Cleanup in incremental compiler
> 
> This CL addresses comments from previous CLs, renaming variables and
> handles change package versions.
> 
> Change-Id: I83cf4a33bffe82ec137a32710cd6e8ff7f25ec8b
> Reviewed-on: https://dart-review.googlesource.com/49161
> Reviewed-by: Peter von der Ahé <ahe@google.com>
> Commit-Queue: Jens Johansen <jensj@google.com>

TBR=ahe@google.com,jensj@google.com

Change-Id: I29a7d5cbd842fd2dddf0373c4e7d0e2ff55da31a
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/49626
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Siva Annamalai <asiva@google.com>
2018-04-05 05:07:37 +00:00
Jens Johansen 5367304ba5 Cleanup in incremental compiler
This CL addresses comments from previous CLs, renaming variables and
handles change package versions.

Change-Id: I83cf4a33bffe82ec137a32710cd6e8ff7f25ec8b
Reviewed-on: https://dart-review.googlesource.com/49161
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2018-04-04 13:11:43 +00:00
Jens Johansen 8ac9fa5de2 Rename simple to basic; get rid of name in tests
This CL follows up on a previous CL, renaming "simple tests" to
"basic tests" and gets rid of names in tests, as they no longer matter.

Change-Id: Id66368f26f8e2e36a8034d237f1708b30562de86
Reviewed-on: https://dart-review.googlesource.com/49160
Reviewed-by: Peter von der Ahé <ahe@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
2018-04-04 13:11:33 +00:00
Peter von der Ahé e21b54159f Tests incremental compilation of parts in packages.
Change-Id: Ic432bc255df1fe356f281779132a92391e3a0c6c
Reviewed-on: https://dart-review.googlesource.com/48100
Reviewed-by: Jens Johansen <jensj@google.com>
Commit-Queue: Peter von der Ahé <ahe@google.com>
2018-03-23 09:30:25 +00:00
Jens Johansen 83bfbcdd96 Incremental compilation: computing class hierarchy for reachable things only
When incrementally compiling, we can have builders for things that aren't
included anymore. Such builders should not introduce errors.

Change-Id: Ia0487d84819028913d54f6b55a2882e620009bd9
Reviewed-on: https://dart-review.googlesource.com/47223
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-22 09:08:46 +00:00
Jens Johansen 0dd2a8dbdb Incremental compiler: Only include libraries loaded from dill if used
Prior to this CL, if loading a library from the dill file what ends
up being unused in the new program it would still be included in the
output. This CL introduces a test and fixes the problem.

Change-Id: I60dd9c3b6bdb959e103f0d2a5653d036b6653140
Reviewed-on: https://dart-review.googlesource.com/46983
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-22 09:08:46 +00:00
Jens Johansen bb2bf609be Incremental compiler: Deal with disappearing package
Prior to this CL, if incrementally compiling something and the .packages
file changed we could get a crash when trying to translate a package url.
This CL introduces a test and fixes the problem.

Change-Id: Ie1874780df7ade394eecef05835b0d9203f4c2b5
Reviewed-on: https://dart-review.googlesource.com/46982
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-22 08:57:36 +00:00
Jens Johansen 2e366e8c9a [fasta] Refactor incremental_load_from_dill_test
Split into 2:
- One with a "smoke-test" of dart2js.
- One with several small examples that has caused problems in the past.

The latter of the two is now based on package:testing and the test-cases
are saved as yaml files.

Change-Id: I8b588e9b42edc73f58a07292a1226e37cc458d89
Reviewed-on: https://dart-review.googlesource.com/45505
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
2018-03-22 08:57:36 +00:00