Instead of bailing out with FATAL et al (which shuts down the VM),
give an ApiError when the dill file is invalid.
Bug: #33577
Change-Id: I8354b4e68ee95e36584284fd15b3abab3c3bf980
Reviewed-on: https://dart-review.googlesource.com/61937
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
New test was added in d2d47acdce.
It fails - as many others - in `compiler == app_jitk` mode.
Change-Id: Id2ab4aec2e7f631a206490d46fefc614b4d666f5
Reviewed-on: https://dart-review.googlesource.com/62148
Reviewed-by: Jens Johansen <jensj@google.com>
Using strstr in a loop is O(n^2) with n being the length of the path,
whereas using strncmp is O(n*m) with n being the length of the path
and m is the length of the separator (which is always 1).
Effectively this turns the quadratic behavior linear.
Change-Id: If60d02c33eeca92ca2ff52e0df97d0bb80fe57e0
Reviewed-on: https://dart-review.googlesource.com/62144
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
Commit-Queue: Jens Johansen <jensj@google.com>
Previously, if we didn't include the source code, we wrote the url as
null. This for instance made it impossible to step through mixed in code
(at least when mixed in from the sdk).
This CL includes all used urls. If there's no source, the source is empty,
but the VM then tries to find the proper source to be able to display it
(e.g. the VM already has the sdk source).
This CL further more adds a service test that tests that we can actually
step into mixin in code from the sdk.
Change-Id: Ied9569723e23928769ebc980410aed60be6eaa22
Reviewed-on: https://dart-review.googlesource.com/51621
Commit-Queue: Jens Johansen <jensj@google.com>
Reviewed-by: Vyacheslav Egorov <vegorov@google.com>
+ improve the commonSubclasses implementation to support the
implementation of FlatTypeMask.intersection and RuntimeEquals.equals
computation.
Change-Id: I51c4d229e9dc6d5de101aff33e56bb44bf93bc0d
Reviewed-on: https://dart-review.googlesource.com/61927
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
When on Windows, look for '/' in addition to standard Windows file path separator.
Bug: dartbug.com/33590
Change-Id: If07daea4d1eaa4e38c051304e63aa95eaf302ed6
Reviewed-on: https://dart-review.googlesource.com/62260
Commit-Queue: Alexander Aprelev <aam@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Update front_end and vm deps to be path dependencies
Change-Id: I5cd6b80bab6ae5f2ddfa986abf2b0af5369cab1a
Reviewed-on: https://dart-review.googlesource.com/61907
Reviewed-by: Sigmund Cherem <sigmund@google.com>
This extends existing support for multiroot compilation from frontend server to kernel service.
Bug: dartbug.com/33508
Change-Id: I76e49038765793b4d683869ab812dde5e6baf6c4
Reviewed-on: https://dart-review.googlesource.com/61982
Commit-Queue: Alexander Aprelev <aam@google.com>
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Reviewed-by: Siva Annamalai <asiva@google.com>
Updated to pass --dfe to invocations of the
checked-in SDK.
Change-Id: I47e122422926d235f166972669c8c2cb18a89735
Reviewed-on: https://dart-review.googlesource.com/62201
Reviewed-by: Siva Annamalai <asiva@google.com>
Commit-Queue: Zach Anderson <zra@google.com>
A change made it check for a unary function type before a binary, so `(o, [stack])=>...` would not get a stack trace.
Fixes#33589
Bug: http://dartbug.com/33589
Change-Id: I69793eb74501c1f7fe07b6c90115b2f90f4d95df
Reviewed-on: https://dart-review.googlesource.com/61936
Reviewed-by: Florian Loitsch <floitsch@google.com>
Commit-Queue: Lasse R.H. Nielsen <lrn@google.com>
It's possible that the code relies upon this async gap. However, I
imagine it isn't, and that the await was merely added in these places
because it looks like it would be an asynchronous operation. In any
case, it was not waiting on anything before, and so any reliance upon
any async gaps here would be strange.
Change-Id: I49c3be4dcaaa18361ef60c7f9e31999db3fc090b
Reviewed-on: https://dart-review.googlesource.com/60704
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
This improves the parser's ability to distinguish between an expression
and the start of a new statement.
Change-Id: I07871dc0e2e6f81996bfc99a53bd3dede3db21ae
Reviewed-on: https://dart-review.googlesource.com/62180
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
- Fixes requestFullscreen to call operation webkitRequestFullscreen not requestFullscreen its only available when RuntimeEnabled=FullscreenUnprefixed.
Fixes#21919R=vsm@google.com
Change-Id: Ib4c4140350d3cef096954e67010f922df9f2310a
Reviewed-on: https://dart-review.googlesource.com/60702
Commit-Queue: Terry Lucas <terry@google.com>
Reviewed-by: Vijay Menon <vsm@google.com>
There is a seeming parse error in typedefs, and an open question on the
issue (33343) about what to do when a generic function type is inferred.
Otherwise this seems ready to go.
Bug: 33343
Change-Id: I10d2ea9b6ca26ed2c6ff6b24ffe5008fc4797ef2
Reviewed-on: https://dart-review.googlesource.com/61109
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
It turns out they aren't needed--the required functionality is already
provided by the variableAssign method.
Fixes#33557.
Change-Id: Ieb3cfc237a6d7d6ae61f0afcd9e9bb9ead1c8fbb
Reviewed-on: https://dart-review.googlesource.com/62125
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
This fixes a crash when parsing assert statements
and improves recovery when missing a closing ')'.
Change-Id: I1495dad40208918fb93a65234f3fe7e94b2c6aae
Reviewed-on: https://dart-review.googlesource.com/62160
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
Does not handle the other half of #33343, rejecting generic function
types as type arguments.
This revealed a secondary minor issue which was easy enough to fix. Type
arguments were not resolved within bounds:
class C<T extends S Function<S>(S)> {}
this would report 'undefined class S' for the return and parameter types
`S`. I almost split this into a separate CL, but, these two CLs are tied
together inherently by the tests case. Easy to solve at once.
Bug: 33343
Change-Id: Ib34a04d90be08d8d6c6f21a9d485a452017585ba
Reviewed-on: https://dart-review.googlesource.com/61103
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Paul Berry <paulberry@google.com>
Change-Id: I88866d54f97455fd9b14fef7def20d6dd958b878
Reviewed-on: https://dart-review.googlesource.com/59088
Commit-Queue: Dmitry Stefantsov <dmitryas@google.com>
Reviewed-by: Peter von der Ahé <ahe@google.com>
It should expand past abstract classes if that allows to merge
two consequtive ranges with the same target into one.
In Dart 2 mode cid ranges are often interrupted by
abstract classes introduced by mixin transformation.
This change allows to expand ranges past those classes and
merge consequtive ranges that have the same target.
Change-Id: Ic0f4fa956d989609bebbe6f8d275491c562aa492
Reviewed-on: https://dart-review.googlesource.com/61929
Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
ExpressionJudgment.infer is the method that will compile from type
inference judgments to abstract syntax. Change it to have this API.
It currently returns null from all implementations.
Change-Id: Id3bdac43a2783c4fda0aeeeff2963d0ccee4dd20
Reviewed-on: https://dart-review.googlesource.com/61935
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
Commit-Queue: Kevin Millikin <kmillikin@google.com>
Must demangle the name before checking if it is a setter name.
Change-Id: I2d58b9d4d5cab319f67da045458277e9f42e2592
Reviewed-on: https://dart-review.googlesource.com/61933
Reviewed-by: Jens Johansen <jensj@google.com>
Commit-Queue: Vyacheslav Egorov <vegorov@google.com>
Previously, when loading from a dill file and not invalidating anything
compilation expression would fail.
This CL introduces a forced invalidation of the entrypoint when loading
for the first time, just as is done when requesting a full component.
Closes#33087.
Bug: 33087
Change-Id: I0d9b84393f3b046a0359e3a94bb1bcb8ab650308
Reviewed-on: https://dart-review.googlesource.com/61920
Reviewed-by: Kevin Millikin <kmillikin@google.com>