Brian Wilkerson
b85c68a73c
Collect and print information about the worst completion results
...
Change-Id: I38e1d2a587f80ed4ee0da75f875b94aff922fe3a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/142064
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Jaime Wren <jwren@google.com >
Reviewed-by: Phil Quitslund <pquitslund@google.com >
2020-04-01 21:45:48 +00:00
Konstantin Shcheglov
191be51124
Extract GenericInferrer and type schema.
...
Change-Id: Ic306342609911e3e232dbf95f30b60cff94c34be
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/142062
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-04-01 20:54:48 +00:00
Jaime Wren
a14d41958e
Modify the completion_metrics.dart file to ignore named arguments in dynamic or unknown method calls.
...
This is a follow up on https://dart-review.googlesource.com/c/sdk/+/140775
Change-Id: Id84271f1bc8559f516c2c4e09c2b66dc10462f3f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141915
Commit-Queue: Jaime Wren <jwren@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-04-01 18:26:32 +00:00
Paul Berry
278a2db4df
Add a --preview-port flag to dart migrate.
...
Change-Id: I526a2e40198960e0e3fb3509ed8a84979f520b07
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141765
Commit-Queue: Paul Berry <paulberry@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
2020-04-01 12:10:04 +00:00
Paul Berry
b7130b0bf7
Migration: improve preview tool display when ! is added due to an explicit hint.
...
Change-Id: Ie9b2a6cabaf02c46da2e8b8ac1bffa0e699acc64
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141741
Reviewed-by: Mike Fairhurst <mfairhurst@google.com >
2020-03-31 22:04:46 +00:00
Konstantin Shcheglov
ca6b0fd0df
Fix for crash in WrapInText when the parameter is not InterfaceType.
...
There was a crash in the logs.
_TypeError: type 'GenericFunctionTypeElementImpl' is not a subtype of type 'ClassElement'
at WrapInText.compute (wrap_in_text.dart:26 )
at FixProcessor._addFromProducers.compute (fix_internal.dart:4506 )
at FixProcessor._addFromProducers (fix_internal.dart:4520 )
at FixProcessor.compute (fix_internal.dart:762 )
at DartFixContributor.computeFixes (fix_internal.dart:82 )
R=brianwilkerson@google.com , pquitslund@google.com
Change-Id: I187b3348a212391cc6c64ab2c412653bd2319334
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141820
Reviewed-by: Phil Quitslund <pquitslund@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-03-31 15:56:40 +00:00
Konstantin Shcheglov
fb4b59e043
Deprecate isProxy / isOrInheritsProxy in ClassElement.
...
R=brianwilkerson@google.com , paulberry@google.com
Change-Id: Ied4011961d4dece33d527888d274893985d85f93
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141767
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-03-30 23:27:39 +00:00
Jaime Wren
11d6bc6055
Comment out the currently incomplete available suggestions work to ensure that the output is accurate for non-available suggestions users
...
Change-Id: I094392cb81edf5c0c7b11702ba42e5d2c80a1453
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141760
Commit-Queue: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Auto-Submit: Jaime Wren <jwren@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-03-30 22:08:19 +00:00
Mike Fairhurst
0943e6136d
[nnbd_migration] Save line number of details to preserve on reload.
...
When clicking on a region, store its offset & line in the URL via
`pushState`, so that on reload (after rerun migration or after apply
edit, or just in general) the context isn't lost.
Note that offset is not enough. Basically, every navigable element gets
a class `o$offset`, and if the page is loaded with some offset such
that no element with class `o$offset` exists, it falls back to line
number. And if there were edits mode before the region since reload,
there will only be an element `o$offset` if you are lucky.
Change-Id: Ic5fd83aceb4e8731348e70c039fec2ca2a6ab9e4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141465
Commit-Queue: Mike Fairhurst <mfairhurst@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
2020-03-30 21:41:59 +00:00
Brian Wilkerson
93313eb244
Enable omit_loval_variable_types in analysis_server_client
...
Change-Id: I21271bfc6b2b7949fcafc5f91f23f8364697bcfc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141580
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-30 03:59:07 +00:00
Brian Wilkerson
8969b1839c
Enable omit_local_variable_types in analysis_server
...
Change-Id: I7e5c13d40fd276854601681fc84be321e6031b10
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141583
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-30 03:58:44 +00:00
Konstantin Shcheglov
3a0bf3ad36
Fix for creating a setter when the target is in a part without a library.
...
R=brianwilkerson@google.com
Change-Id: I3c364f01c9cb31166e24f2b28d6a4640fa7d8c93
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141560
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-03-28 21:00:23 +00:00
Brian Wilkerson
a564026dc7
Remove the need for a --corpus flag from completion_metrics
...
Change-Id: Id395b3f4d58a072c435d97920a573379439d8580
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141471
Reviewed-by: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-28 17:50:53 +00:00
Brian Wilkerson
2b4f12f3c5
Remove the need for a --corpus flag from relevance_metrics
...
Change-Id: I7dacc57728258a9cbbe481950d618bbe73bfa22f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141470
Reviewed-by: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-28 17:50:44 +00:00
Brian Wilkerson
7e724e70b0
Sort non-generated files in analyis_server and add a test to ensure they stay that way
...
Change-Id: I6c7a38cefa69f46737bd50eefe2fbb88c127017b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141520
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-28 17:12:03 +00:00
Brian Wilkerson
232052da06
New relevance values for UriContributor
...
Change-Id: I32a3151cb78a333ef7e23e89f2688acb4c74edb4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141480
Reviewed-by: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-27 22:51:34 +00:00
Brian Wilkerson
c3fc96ad62
New relevance values for KeywordContributor
...
Change-Id: I851e9fa12bc674b6714089fa2b23443c2e2140d2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141463
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Jaime Wren <jwren@google.com >
2020-03-27 22:37:59 +00:00
Brian Wilkerson
8a126788fc
New relevance values for VariableNameContributor
...
Change-Id: Id2670c4ec0860ce246a44dfe2abd8b6dbf987a35
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141462
Reviewed-by: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-27 22:37:51 +00:00
Mike Fairhurst
104bdcd4cc
[nnbd_migration] Add confirm dialog to "apply migration" button
...
Change-Id: I377caf627725c6f38eeca34001e61ab23323a700
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141029
Commit-Queue: Mike Fairhurst <mfairhurst@google.com >
Reviewed-by: Janice Collins <jcollins@google.com >
Auto-Submit: Mike Fairhurst <mfairhurst@google.com >
2020-03-27 19:50:57 +00:00
Brian Wilkerson
127d84aa56
Update relevance computations in LocalReferenceContributor
...
Change-Id: I19baafc28488304d781757c2a2648ec3d3781d15
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141361
Reviewed-by: Phil Quitslund <pquitslund@google.com >
Reviewed-by: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-27 18:33:29 +00:00
Brian Wilkerson
db91583b38
Update relevance values for LocalLibraryContributor and ImportedReferenceContributor
...
Change-Id: I204bd8a95d9697f166e8e0a97d36098fc35c1dc1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141206
Reviewed-by: Phil Quitslund <pquitslund@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-27 18:30:08 +00:00
Mike Fairhurst
62c4b1fb2e
[nnbd_migration] Add a "rerun from sources" button.
...
Change-Id: I09f1c76cb41549b81218783ec69d190271508ba0
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141028
Commit-Queue: Janice Collins <jcollins@google.com >
Reviewed-by: Janice Collins <jcollins@google.com >
2020-03-27 16:50:12 +00:00
Brian Wilkerson
7d66feb5ff
Compute new relevance in LocalConstructorContributor
...
Change-Id: Ife24a24829fae36b1caef5ab0a55e4c210a063a1
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141201
Reviewed-by: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-26 21:50:29 +00:00
Janice Collins
da1d9eb1bd
Add a way for analysis_server to open communication via a IsolateChannel.
...
The idea is to pass a SendPort as an optional parameter to
ServerStarter.start(), and if present, key server behavior around
behaving well as an isolate.
Bug: https://github.com/dart-lang/sdk/issues/41056
Change-Id: Ifc6ac2fefcf6aae8bce712e470524d1c06fa2ba6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140373
Commit-Queue: Janice Collins <jcollins@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
2020-03-26 21:37:59 +00:00
Sam Rawlins
fe6f3eaf9f
Migrator: Add an auth token for the preview site
...
Fixes #41134
Change-Id: I6d436805d3dfb64cc4d7ddde2b307132fbd1365d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140621
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Samuel Rawlins <srawlins@google.com >
2020-03-26 20:01:56 +00:00
Mike Fairhurst
3095a082cd
[analyzer] Add an API to get a language comment token off a unit.
...
Change-Id: I377fdc44d5e514d6d9a601b3947c3908e5a4497a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140768
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-03-26 03:47:57 +00:00
Brian Wilkerson
d194838578
Add new relevance scores to LibraryElementSuggestionBuilder, which covers both LibraryMemberContributor and CombinatorContributor
...
This should have tests, but I (or someone else) need to do some data
mining to figure out the correct relevance values and hence the correct
ordering to test for.
Change-Id: I7782d7b7e13ff38a785c445cd0d6fc82a388a6aa
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/141000
Reviewed-by: Phil Quitslund <pquitslund@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-25 22:49:26 +00:00
Brian Wilkerson
df5e6c8e5f
Compute new relevances in LibraryPrefixConstributor
...
Once again, test suggestions are welcome.
Change-Id: I470825a0ef51f555977bdc86192cc38bd718519a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140943
Reviewed-by: Jaime Wren <jwren@google.com >
Reviewed-by: Phil Quitslund <pquitslund@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-25 21:01:16 +00:00
Mike Fairhurst
5f20fe7d83
Revert "Trim not useful bottoms off of the non/nullability stack traces"
...
This reverts commit a225178919 .
Reason for revert: This seems to remove useful info from the stack trace. Will revert, then hopefully land an improved version.
Original change's description:
> Trim not useful bottoms off of the non/nullability stack traces
>
> Change-Id: I2f7bfab13fd3d70c5cbdbb10ce14a8a91f8c7a60
> Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140000
> Commit-Queue: Samuel Rawlins <srawlins@google.com >
> Reviewed-by: Paul Berry <paulberry@google.com >
TBR=paulberry@google.com ,mfairhurst@google.com ,srawlins@google.com
# Not skipping CQ checks because original CL landed > 1 day ago.
Change-Id: I9a2fb07e387d57394242b694e27456333f2cf2b8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140908
Reviewed-by: Mike Fairhurst <mfairhurst@google.com >
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Mike Fairhurst <mfairhurst@google.com >
2020-03-25 20:57:36 +00:00
Brian Wilkerson
3abbcd0da9
Attempt to fix windows bot failure
...
Change-Id: I6288838fe5dea2cb7b8e0d79ee90d09c91496769
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140901
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Auto-Submit: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2020-03-25 20:39:56 +00:00
Paul Berry
244b4247e9
Migration: better description text for edges.
...
Change-Id: I58651c927a741721283c3c4c951673a86aa7a1b3
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140883
Reviewed-by: Mike Fairhurst <mfairhurst@google.com >
2020-03-25 19:38:34 +00:00
Brian Wilkerson
9e4eb054a4
Add new relevance scores for NamedConstructorContributor
...
Change-Id: I6e5fd10edf74b44afb766acd675dffd5ef0cb25f
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140906
Reviewed-by: Phil Quitslund <pquitslund@google.com >
Reviewed-by: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-25 17:47:42 +00:00
Brian Wilkerson
2323087237
Fix the comment for the LabelContributor
...
Change-Id: I8ac9f343608b04b7fe1ec59a9d151dd6dd81e926
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140902
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-25 16:39:12 +00:00
Sam Rawlins
1aab8bccd0
Add a dev mode to Migrator preview site compiler
...
Change-Id: I355ca9f89371e497370664ed8733a581c5958ae5
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140763
Reviewed-by: Mike Fairhurst <mfairhurst@google.com >
Commit-Queue: Samuel Rawlins <srawlins@google.com >
2020-03-25 14:49:32 +00:00
Lasse R.H. Nielsen
8760283247
New implementation of runZoned.
...
A combination of `runZoned` and `runZonedGuarded` where only the latter allows an `onError` parameter,
and only that has a nullable return type.
Retains the `onError` parameter on `runZoned` for now because it's too breaking to remove it until packages have been migrated off of it.
It will be removed in a follow-up CL.
Change-Id: If0e86c8d14e13fa089c66f4af975aeacb2616cf6
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/137302
Reviewed-by: Jake Macdonald <jakemac@google.com >
Reviewed-by: Nate Bosch <nbosch@google.com >
2020-03-25 00:24:33 +00:00
Brian Wilkerson
ef56e3a3fc
Update relevance of labels
...
Change-Id: Id862fa2da7969a9dcdb1854f6ffe38a4c122a024
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140778
Reviewed-by: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-24 22:46:07 +00:00
Brian Wilkerson
7e0190a6d7
Add new relevance values for field formal parameter suggestions
...
Also updated a comment that I missed from the last CL.
Change-Id: Ibfcce19998532c672b9990308cd7b03fd42d14cf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140772
Reviewed-by: Jaime Wren <jwren@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2020-03-24 20:46:27 +00:00
Jaime Wren
81894b958f
Fix another case of the form described in https://github.com/dart-lang/sdk/issues/41039 , this fixes the FunctionDeclaration case.
...
Bug: https://github.com/dart-lang/sdk/issues/41039
Change-Id: I03df7f8d92b1e7754410dc88e1c09ad83476960e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140769
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Jaime Wren <jwren@google.com >
2020-03-24 19:11:15 +00:00
Brian Wilkerson
2d0fed35bb
Update the ArgListContributor to have new relevance scores
...
This also includes a new metric computation showing how often function
typed parameters have closures as arguments.
Change-Id: I8999cc3935bcc7514ebba90a8a4d246b2f236c42
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140702
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Phil Quitslund <pquitslund@google.com >
Reviewed-by: Jaime Wren <jwren@google.com >
2020-03-24 17:00:55 +00:00
Mike Fairhurst
799560bff7
[nnbd_migration] Remove language version comments during migrate
...
Bug: 41095
Change-Id: I3262d6da485d78fee1e2dfe4ac22692c5e4b6daf
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140369
Reviewed-by: Janice Collins <jcollins@google.com >
Commit-Queue: Mike Fairhurst <mfairhurst@google.com >
2020-03-24 16:44:05 +00:00
Sam Rawlins
5a1a83275c
Migrator: Scroll the Edit Details panel into view when refreshing the contents
...
Change-Id: I577d165189c0a790774f2ac7c44fe9c70367bfbc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140370
Reviewed-by: Janice Collins <jcollins@google.com >
Commit-Queue: Samuel Rawlins <srawlins@google.com >
2020-03-24 14:12:49 +00:00
Devon Carew
1e45051341
[analyzer] initial implementation of SDK, file based configuration of the analysis server
...
Change-Id: Iff3808fb073b062fa566993e7f05e2669a5fde7e
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140003
Commit-Queue: Devon Carew <devoncarew@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2020-03-24 14:07:59 +00:00
Erik Ernst
e3af7e724f
Update usage of int/String fromEnvironment
...
Breaking change 40678 requires the constructors int.fromEnvironment and
String.fromEnvironment to get new default values for the named
parameter `defaultValue`. This CL changes usages of these constructors
such that they do not depend on the default value, such that it
becomes a non-breaking change for code in the SDK repo to perform the
change in sdk and in sdk_nnbd.
Change-Id: I82af0e1f92d6cd3618b65c0c50d754ae8c39eb0a
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140284
Reviewed-by: Lasse R.H. Nielsen <lrn@google.com >
Reviewed-by: Leaf Petersen <leafp@google.com >
Commit-Queue: Erik Ernst <eernst@google.com >
2020-03-24 11:19:14 +00:00
Konstantin Shcheglov
6b7d7aa2c1
Type Function should be excluded from extended / implemented / mixed types.
...
Change-Id: If225400a976657f042856bfdaf95b285f98cebb4
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140660
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2020-03-23 20:35:37 +00:00
Jaime Wren
6219daa274
Preventatively check for null from the return of AstNode.findPrevious(..). This was the only instance of a missing null check in analyzer, analyzer_plugin, analysis_server and analyzer_cli.
...
Context: https://dart-review.googlesource.com/c/sdk/+/140245 (cases in code completion)
Bug: https://github.com/dart-lang/sdk/issues/38681
Change-Id: I951811034976041c425e74a52f33d27f13781015
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140253
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Auto-Submit: Jaime Wren <jwren@google.com >
2020-03-23 18:08:16 +00:00
Jaime Wren
6f76f194b1
Fix the common case of https://github.com/dart-lang/sdk/issues/41039 , around MethodDeclarations
...
Code completion will now include void, dynamic and other class declaration keywords in the return type location, in the following snippet: '@override void someMethod(...) {}'
This is relatively common, this happens 103 times in the collection package.
Bug: https://github.com/dart-lang/sdk/issues/41039
Change-Id: I28129f2d735d2ff7d0a0e65194b7963c74b01c51
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140360
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Jaime Wren <jwren@google.com >
2020-03-23 18:03:44 +00:00
Jaime Wren
dd95365f76
Optimization for the MeanReciprocalRankComputer. This change doesn't have the object hold onto the list of ranks for the entire duration of a run, but has a running sum instead (similar to ArithmeticMeanComputer).
...
This would have been an over-optimization originally, but at this point, we have 10 of these computer objects in completion_metrics.dart, and we are running this algorithm with up to 1.2 million ranks.
(Assuming that an int takes 4 bytes which I believe is true...) On a recent run of Brians, 29.4 MB of data was the running total of all the ranks. With this change, the same data will be stored with 10 doubles and 10 ints.
Change-Id: If97ca18e78782c02a3ca0a3ed9d6a9725f5a05ea
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140321
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Jaime Wren <jwren@google.com >
2020-03-21 19:50:36 +00:00
Sam Rawlins
0fdc2816c0
Migrator: Improve scrolling behavior for elements near top or bottom
...
Change-Id: I24f951d6e16b8175e15af1bff32ed0d7d58a39b2
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140367
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Samuel Rawlins <srawlins@google.com >
2020-03-20 23:17:15 +00:00
Sam Rawlins
b6ef199bc0
Migrator: fix test to assert on information region when not making a parameter nullable
...
Change-Id: I1df34c06ec0f6ffac29fcef873ab7a83e7636044
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140249
Reviewed-by: Paul Berry <paulberry@google.com >
Commit-Queue: Samuel Rawlins <srawlins@google.com >
2020-03-20 18:30:28 +00:00
Jaime Wren
6238c6c0f9
Add missing null checks for return values from AstNode.findPrevious(..)
...
The documentation on [findPrevious] reads: "Return the token before [target] or `null` if it cannot be found."
Bug: https://github.com/dart-lang/sdk/issues/38681
Change-Id: I3f9d0418e7ea4efa5190da895a3932bf91f160d8
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/140245
Commit-Queue: Jaime Wren <jwren@google.com >
Commit-Queue: Phil Quitslund <pquitslund@google.com >
Auto-Submit: Jaime Wren <jwren@google.com >
Reviewed-by: Phil Quitslund <pquitslund@google.com >
2020-03-20 17:52:12 +00:00