Commit Graph

25510 Commits

Author SHA1 Message Date
Jenny Messerly 7fe4253a4e [analyzer] fix #36158, implicit cast missing on covariant return type
Due to API changes, the implicit cast visitor (CodeChecker) was not
finding the correct substituted member type, so the implicit return
type cast was not inserted.

Also fixes another issue that paulberry@ discovered: covariant return
type casts were overwriting the implicit casts from the context type.
The context type should always take priority; implicit covariance
checks are only needed when there isn't a type cast from the context.

Change-Id: I998e8f87371c15175c57864b7e334449268fe339
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97143
Reviewed-by: Paul Berry <paulberry@google.com>
2019-03-20 00:33:41 +00:00
Nate Bosch 7e14f2aded Removed mirror methods from DeferredLoadTask
These methods are not used and the only implementation throws.

Change-Id: I0174f9fd43447b8f49f63844a39aa90d40258f64
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97348
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Nate Bosch <nbosch@google.com>
2019-03-20 00:15:12 +00:00
Nate Bosch dec7e65334 Delete Flags.enableExperimentalMirrors
Nothing is reading this option.

- Change the option handler to ignore to avoid breaking users passing it
  anyway.
- Remove the Flag constant.
- Remove the option.

Change-Id: I62f3b6ce7b3cf38ad310576b011d27ac78353fde
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97346
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Nate Bosch <nbosch@google.com>
2019-03-20 00:11:54 +00:00
Alan Knight 7eabbe70cd Make the --repl-compile option visible
Change-Id: I6da7062cf9357b2c8f53b980dc33827b7147f111
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97173
Reviewed-by: Jenny Messerly <jmesserly@google.com>
Commit-Queue: Alan Knight <alanknight@google.com>
2019-03-20 00:04:13 +00:00
Mike Fairhurst 9c8e6dc42c [analyzer] rewrite mostSpecificTypeArgument to use asInstanceOf
Change-Id: If7c9e9e9cdc1999c6f7d3c74d081a457f9fc229e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97278
Auto-Submit: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
2019-03-19 22:50:19 +00:00
Mike Fairhurst 337a252c31 [analyzer] UI as code test cleanup
Change-Id: I73300a2aa5cfa1a9043454e462ac1df2840ee308
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97271
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
2019-03-19 22:00:29 +00:00
Mike Fairhurst d0bdfee041 Fix DDC cast -- cast key/value/element individually & don't clobber names.
Change-Id: Id5175782667b760545dac15b02c2a41836137571
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97178
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
Auto-Submit: Mike Fairhurst <mfairhurst@google.com>
2019-03-19 21:06:48 +00:00
Konstantin Shcheglov 67243e0396 AstTextPrinter that prints AST tokens into their original positions.
R=brianwilkerson@google.com, paulberry@google.com

Change-Id: I3ca2167c43408c535f61179ec7ea701acd65cc57
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/95600
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-03-19 20:57:29 +00:00
Konstantin Shcheglov d214646d89 Remove TestAnalysisContext and related.
R=brianwilkerson@google.com

Change-Id: I94030893b9c65e8f6c854a8453d12734ef08e690
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97270
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-03-19 20:34:29 +00:00
Jenny Messerly 22c535ac6e [dartdevc] simplify code for emitting constants
This moves the code into a shared location (instead of being copied to
both of the Analyzer/Kernel-based backends), and removes support for
detecting type parameters in constants, which was allowed by strong
mode but is not legal in Dart 2.

Change-Id: Ic8bcf0aa1107bbb7147fd15b648a45e39478cef5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/96839
Commit-Queue: Jenny Messerly <jmesserly@google.com>
Auto-Submit: Jenny Messerly <jmesserly@google.com>
Reviewed-by: Nicholas Shahan <nshahan@google.com>
2019-03-19 19:45:04 +00:00
Mike Fairhurst 040fa0f83c Add undefined identifier test for for loops
Change-Id: I590a76525c8f50b28dd3a4a4be448806e4b83027
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97264
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
Auto-Submit: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-03-19 19:40:09 +00:00
Konstantin Shcheglov 85e5684863 Remove OptionsWorkManager and GenerateOptionsErrorsTask is not a task.
R=brianwilkerson@google.com

Change-Id: Ic257c13a553835f78bd7bc0778dd33c327097af9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97284
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-03-19 19:03:03 +00:00
Nate Bosch 33100aa1ce Delete some copy/pasted doc comments
Where we have an `@override` which duplicate's the super types doc
comment it is not adding anything useful and can be removed.

Also do some minor comment cleanup where feasible:
- Introduce blank lines following the first sentence to follow effective
  dart guidelines.
- Change non-doc comments to use two slashes.
- Where comments were improved after being pasted, bring the improvement
  to the original comment.
- Move comments where there was no comment on the super type but the
  subtype comment clearly applied.

Change-Id: I61b5eca79f692641ce96c5c9d26fa3731c8e230e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97008
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Nate Bosch <nbosch@google.com>
2019-03-19 18:43:07 +00:00
Nicholas Shahan 55f3edadbe [dartdevc] Initial support for spread collections
- Only supports ddc with analyzer front end.
- Basic support for SpreadElement nodes used in collection literals.

Issue: #36006
Change-Id: I9b78c6ff34847625c8013a8e7af9a0f05a67541b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97045
Commit-Queue: Nicholas Shahan <nshahan@google.com>
Reviewed-by: Jenny Messerly <jmesserly@google.com>
2019-03-19 16:56:08 +00:00
Konstantin Shcheglov 2ceaccf5f6 Report EQUAL_ELEMENTS_IN_CONST_SET.
R=brianwilkerson@google.com, paulberry@google.com

Change-Id: I6f358c4f78deabc575479070d3ff23efb438ae64
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97177
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-03-19 15:55:18 +00:00
Dan Rubel 0c34bf13ea update ElementResolver postfix NNBD bang processing
Change-Id: I700bedc55c42da914fab6d25f4f3620a6ce0b022
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97266
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-03-19 15:35:26 +00:00
Paul Berry 9788949db8 Run dartfmt on pkg/analyzer/test/dart/ast/ast_test.dart
Change-Id: Id7388677356bc2af20278eb9e8f5df459fe4df85
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97282
Commit-Queue: Paul Berry <paulberry@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Auto-Submit: Paul Berry <paulberry@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-03-19 15:25:16 +00:00
Aske Simon Christensen d012972c8d [CFE] Fold the asExpression call into the unique function.
Change-Id: I9518c0dd9a76e23795ec80a69f1b304a6833d373
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97085
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2019-03-19 15:23:36 +00:00
Aske Simon Christensen ee1e036adf [CFE] Lazy constant evaluation for maybe-evaluated expressions.
Change-Id: I21d21b33902b63a4769d6f4b342ec285c9ab46ee
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/96783
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2019-03-19 15:23:36 +00:00
Aske Simon Christensen 330b958e20 [CFE] Check for null in constant evaluation.
Reland of https://dart-review.googlesource.com/c/sdk/+/95520

Change-Id: Ide2243edc1c32db0d55580a98f2de62be23b912b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97226
Reviewed-by: Dmitry Stefantsov <dmitryas@google.com>
2019-03-19 15:23:36 +00:00
Konstantin Shcheglov ca5ac975fe Fix for crash in _DartNavigationComputerVisitor._addUriDirectiveRegion when part has invalid URI.
R=brianwilkerson@google.com

Change-Id: Ia6c62c344cd195449168e5971165a3d37ffc7f67
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97280
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-03-19 14:53:17 +00:00
Konstantin Shcheglov 70e3e67dd7 Expect different errors depending on the state of the spread_collections experiment.
R=brianwilkerson@google.com, paulberry@google.com

Change-Id: Ia12ea33be90ef1d390fd0a6c38fd421c317e6562
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97179
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-03-19 14:37:26 +00:00
Dan Rubel c85108d2f9 Fix parse expression "a ~ b"
This fixes an infinite loop that I introduced in the parser
on Wed Feb 27 commit 8f12d634fe
when adding support for the "!" NNBD postfix assert non-null operator.

To the best of my knowledge, this problem only manifests
when parsing the expression "a ~ b".

Fix https://github.com/dart-lang/sdk/issues/36255

Change-Id: If20f45620eee0f7cf9b4b6a93640bd3b921d23b9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97265
Reviewed-by: Paul Berry <paulberry@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-03-19 14:15:06 +00:00
Paul Berry f890800fb0 Rework tracking of variables in scope while resynthesizing expressions.
The new formulation allows easy popping of variables when leaving
nested scopes.  This should make it easier to support "for" collection
elements that declare variables.

Change-Id: Ie1dbb11c50677936973acef804b2496a0d00a84a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97172
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2019-03-19 14:14:46 +00:00
Stevie Strickland af5fc2d4d2 [VM] Partial support for named regexp captures.
See https://github.com/tc39/proposal-regexp-named-groups
for a high-level description of the feature and examples.  This is one of the
features requested in https://github.com/dart-lang/sdk/issues/34935.

This is a partial implementation because while there is a way to retrieve
groups via Dart by name, it requires casting the returned Match to the
new RegExpMatch interface to avoid changing the RegExp interface.
Changing the RegExp interface will happen in a future update, since there
are other planned changes to the RegExp interface coming soon and that way
we only change it once. See https://github.com/dart-lang/sdk/issues/36171
for more details on the planned changes.

Also, since only BMP regular expressions are supported, not full
Unicode ones (i.e., those with the /u flag in ECMAscript), \k<NAME>
will only be parsed as a named back reference if there are named
captures in the string. Otherwise, the \k will be parsed as the identity
escape for backwards compatibility. The new tests illustrate this
difference.

Change-Id: Ieeb0374813db78924c9aa8ac3e652dfb6d4a5934
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/95461
Commit-Queue: Stevie Strickland <sstrickl@google.com>
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
Reviewed-by: Jenny Messerly <jmesserly@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-03-19 10:40:15 +00:00
Paul Berry 527b10879e Begin adding summary support for for elements.
Change-Id: Icdcfba5caaac34375b65c838dabc97e9b9201ee9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97120
Commit-Queue: Paul Berry <paulberry@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2019-03-18 21:13:10 +00:00
Mike Fairhurst 42ab0a6a63 Handle downcasts for spreads
Change-Id: If87a384a29399123951384b7474cfc8632a7ad0e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97144
Commit-Queue: Mike Fairhurst <mfairhurst@google.com>
Reviewed-by: Jenny Messerly <jmesserly@google.com>
2019-03-18 20:57:10 +00:00
Johnni Winther 9c9ab11450 Reland "Handle ir constants in field analysis and impact tests"
Include initial handling of unevaluated constants from environment.

Change-Id: I288801b42a9e25e440baa3eac9ce88263acea0a7
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97241
Reviewed-by: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Auto-Submit: Johnni Winther <johnniwinther@google.com>
2019-03-18 17:57:55 +00:00
Dan Rubel 91b62553ce Make scanner reportErrors field final
Address comments in https://dart-review.googlesource.com/c/sdk/+/80509

Change-Id: Ifc19f283513f201c6d0935e4b20169a528feab20
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97047
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Dan Rubel <danrubel@google.com>
2019-03-18 17:24:06 +00:00
Paul Berry 1c685bf370 Sort declarations in pkg/analyzer/lib/src/dart/ast/ast.dart
Change-Id: Ic03f94f3e7a2a64d0f19f2240363718082e703f9
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97164
Auto-Submit: Paul Berry <paulberry@google.com>
Reviewed-by: Mike Fairhurst <mfairhurst@google.com>
Commit-Queue: Paul Berry <paulberry@google.com>
2019-03-18 16:31:05 +00:00
Aske Simon Christensen 1ea717f1c9 [CFE] Use Fasta diagnostics in constant evaluator.
The constant evaluator now generates all errors as Fasta diagnostic
messages. The ErrorReporter is simplified to just accept a diagnostic
message, or a notification that the constant evaluator encountered an
invalid expression (presumably put there due to an earlier error).

Also, the flow of control between the error reporter and the internal
abort exceptions is reversed, so the error reporter is now called as a
result of an abort exception being caught by the evaluate method.

Reland of https://dart-review.googlesource.com/c/sdk/+/96300

Change-Id: I7d32b6e98962b6ee781a6c96b593b00ee7fd8a89
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97225
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2019-03-18 15:42:05 +00:00
Aske Simon Christensen 22718f4d60 [CFE] Always call the constant evaluator by the evaluate method.
Reland of https://dart-review.googlesource.com/c/sdk/+/96321

Change-Id: Ifb2b955d500c18a470503bad9f62f47e4c6a1fc5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97117
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2019-03-18 15:42:05 +00:00
Aske Simon Christensen c10ee9971f [CFE] Move constant evaluator to Fasta.
Reland of https://dart-review.googlesource.com/c/sdk/+/96081

Change-Id: Ie9e6a0d26703469396fa6ea4803f49ce387f495b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97224
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2019-03-18 15:42:05 +00:00
Sigurd Meldgaard 9d3988eb67 [vm] First stab at a protobuf aware treeshaker
Relies on https://dart-review.googlesource.com/c/sdk/+/96782
Change-Id: I820e884f96923f9eb9a856faef6442f6ed645fe1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/96162
Commit-Queue: Sigurd Meldgaard <sigurdm@google.com>
Reviewed-by: Martin Kustermann <kustermann@google.com>
2019-03-18 13:07:44 +00:00
Aske Simon Christensen e62391a162 Revert "Handle ir constants in field analysis and impact tests"
This reverts commit 0cd89e5bd1.

Reason for revert: Conflicts with move of constant evaluator.

Original change's description:
> Handle ir constants in field analysis and impact tests
> 
> Include initial handling of unevaluated constants from environment.
> 
> Change-Id: Ibd330a14dfabad1dee95b64ce7015939412374d3
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97112
> Commit-Queue: Johnni Winther <johnniwinther@google.com>
> Reviewed-by: Sigmund Cherem <sigmund@google.com>

TBR=johnniwinther@google.com,sigmund@google.com

Change-Id: Ie01c7dda6152abbf852cd40a00597f019db49e66
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97116
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Commit-Queue: Aske Simon Christensen <askesc@google.com>
2019-03-18 13:01:11 +00:00
William Hesse 3b2e368376 Revert 5 changes with failures
TBR=askesc@google.com

Revert "[CFE] Move constant evaluator to Fasta."

This reverts commit 845b5b2df1.

Revert "[CFE] Always call the constant evaluator by the evaluate method."

This reverts commit 91bc4ec2b9.

Revert "[CFE] Use Fasta diagnostics in the constant evaluator."

This reverts commit c7b572aa29.

Revert "[CFE] Check for null in constant evaluation"

This reverts commit e6d2751e9c.

Revert "Rename import after moving file."

This reverts commit a6e2c5eb4c.

Change-Id: Iadfe087c0110f6f331b82d990213f95d3ef4541b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97223
Reviewed-by: William Hesse <whesse@google.com>
2019-03-18 12:25:32 +00:00
William Hesse a6e2c5eb4c Rename import after moving file.
Fixes error in commit of
https://dart-review.googlesource.com/c/sdk/+/96081

Change-Id: I628de76467ef8696f1c83d919c00821ccedfb852
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97222
Reviewed-by: William Hesse <whesse@google.com>
Reviewed-by: Johnni Winther <johnniwinther@google.com>
2019-03-18 12:11:42 +00:00
Aske Simon Christensen e6d2751e9c [CFE] Check for null in constant evaluation
Change-Id: Iecd63572a29d605bb48dd79f9cd07f135bc6fc68
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/95520
Commit-Queue: Aske Simon Christensen <askesc@google.com>
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2019-03-18 10:42:14 +00:00
Aske Simon Christensen c7b572aa29 [CFE] Use Fasta diagnostics in the constant evaluator.
The constant evaluator now generates all errors as Fasta diagnostic
messages. The ErrorReporter is simplified to just accept a diagnostic
message, or a notification that the constant evaluator encountered an
invalid expression (presumably put there due to an earlier error).

Also, the flow of control between the error reporter and the internal
abort exceptions is reversed, so the error reporter is now called as a
result of an abort exception being caught by the evaluate method.

Change-Id: I66f148cc4e202e328f895ae0b770f9b68c9f3c8e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/96300
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2019-03-18 10:42:14 +00:00
Aske Simon Christensen 91bc4ec2b9 [CFE] Always call the constant evaluator by the evaluate method.
Change-Id: I176139c98e968cd890a05c0517781f8fad4a0d7d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/96321
Reviewed-by: Jenny Messerly <jmesserly@google.com>
2019-03-18 10:42:14 +00:00
Aske Simon Christensen 845b5b2df1 [CFE] Move constant evaluator to Fasta.
This is in preparation for recognizing Fasta-specific nodes in the
constant evaluator, and for using the Fasta diagnostics framework.

Change-Id: I8535fbb68e622f1814a1d577c348d87e573b6b34
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/96081
Reviewed-by: Kevin Millikin <kmillikin@google.com>
2019-03-18 10:42:14 +00:00
Johnni Winther 0cd89e5bd1 Handle ir constants in field analysis and impact tests
Include initial handling of unevaluated constants from environment.

Change-Id: Ibd330a14dfabad1dee95b64ce7015939412374d3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97112
Commit-Queue: Johnni Winther <johnniwinther@google.com>
Reviewed-by: Sigmund Cherem <sigmund@google.com>
2019-03-18 10:30:04 +00:00
Mark Zhou eeb8fc8ccd [dartdevc] Adding support for async operations in block expressions
Moving YieldFinder to shared_compiler


Change-Id: Id4d95447443929376f922005e10f66930630dfaf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97040
Reviewed-by: Jenny Messerly <jmesserly@google.com>
Reviewed-by: Nicholas Shahan <nshahan@google.com>
Commit-Queue: Mark Zhou <markzipan@google.com>
2019-03-17 22:03:22 +00:00
Brian Wilkerson d7ad6b8c67 Ensure that all tests are run via test_all and add a test to ensure that it stays that way
Change-Id: I4a531179823a985f14307cbd444b31605d453d23
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97161
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2019-03-17 19:21:12 +00:00
Konstantin Shcheglov daa6ee6da9 Report NOT_ITERABLE_SPREAD and NOT_MAP_SPREAD.
R=brianwilkerson@google.com

Change-Id: I6668787b5b88d5125852e38bd9d30010e36c354b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97160
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-03-17 17:27:03 +00:00
Konstantin Shcheglov d920a2a5ab Report NON_CONSTANT_XYZ in not taken branches of IfElement.
R=brianwilkerson@google.com

Change-Id: I27e8a3b99140046399cdcc8daaa7ecc28ffa62df
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97010
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
2019-03-16 22:43:34 +00:00
Brian Wilkerson 976b897bd0 Report non-bool conditions in const expressions in evaluation
Change-Id: I6c0297ba6d06f0487b3419037109517479b1b794
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97124
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
2019-03-16 18:52:11 +00:00
Konstantin Shcheglov 1d9f34963e Use StoreBasedSummaryResynthesizer directly in LibraryContext.
R=brianwilkerson@google.com

Change-Id: I29583bf4f63bf47b54982688d0f10df02745f7fe
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97009
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-03-16 18:22:41 +00:00
Brian Wilkerson 43a31ff24e Report equal keys in maps when the keys come from a spread element
Change-Id: I92106a53c2e1752e1ffb1073e124268a692e5905
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97146
Reviewed-by: Konstantin Shcheglov <scheglov@google.com>
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com>
2019-03-16 15:21:01 +00:00
Konstantin Shcheglov 0d5ab9380a Add getNotPotentiallyConstants() and isConstantTypeExpression().
R=brianwilkerson@google.com, paulberry@google.com

Change-Id: I1db7d336f71d307274917d49f8f414217e62dd16
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97005
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com>
Commit-Queue: Konstantin Shcheglov <scheglov@google.com>
2019-03-16 03:11:52 +00:00