Brian Wilkerson
6c5709c44a
Remove the URI of types until we can produce better URIs
...
Change-Id: I50e4361b2736245d8d1af32da15822e416c5b2be
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/99267
Reviewed-by: Ari Aye <ariaye@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-04-12 19:18:01 +00:00
Brian Wilkerson
4fa79e9ded
Remove comments from the token stream
...
Change-Id: Idc5171ad87590d40d26e26000c8fb795f28678dc
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/98704
Reviewed-by: Ari Aye <ariaye@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-04-04 20:43:33 +00:00
Brian Wilkerson
e4fa8904f8
Fix the windows bot
...
Change-Id: I76c4670464869a9f7efcc2c758677b1c2bffe18b
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/98682
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2019-04-04 20:30:13 +00:00
Brian Wilkerson
da15746f4c
Update the production of training data
...
Change-Id: Ib9634c5e5bdd8c0097f55a9cf71054e2a2b6a5fe
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/98287
Reviewed-by: Ari Aye <ariaye@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-04-03 22:36:01 +00:00
Brian Wilkerson
3a3731665f
Initial implementation of server support for training data
...
Change-Id: I4943b8c30575e78c1028d9d0be174f535db99303
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/97841
Reviewed-by: Ari Aye <ariaye@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-03-26 20:32:20 +00:00
Konstantin Shcheglov
b8fc017778
Replace convertAbsolutePathToUri() with toUriStr().
...
Change-Id: Ib34247ce7457ada7e4705714984034387f09a80c
Reviewed-on: https://dart-review.googlesource.com/c/91684
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2019-01-30 20:47:56 +00:00
Konstantin Shcheglov
6de1c478c3
Revert "Revert "Issue 34152. Verify file paths and report INVALID_FILE_PATH_FORMAT.""
...
This reverts commit 3f8ea3f508 .
Change-Id: Ib034895f4cf29492e66dd07b7da1a99ba5e94bf6
Reviewed-on: https://dart-review.googlesource.com/c/90885
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2019-01-24 17:30:41 +00:00
Konstantin Shcheglov
3f8ea3f508
Revert "Issue 34152. Verify file paths and report INVALID_FILE_PATH_FORMAT."
...
This reverts commit 5dab28f27f .
Reason for revert: <INSERT REASONING HERE>
Original change's description:
> Issue 34152. Verify file paths and report INVALID_FILE_PATH_FORMAT.
>
> R=brianwilkerson@google.com , paulberry@google.com
>
> Bug: https://github.com/dart-lang/sdk/issues/34152
> Change-Id: I4a5f3634c342fbcfb3bf39c060cc658d87306312
> Reviewed-on: https://dart-review.googlesource.com/c/90840
> Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
TBR=paulberry@google.com ,scheglov@google.com ,brianwilkerson@google.com
Change-Id: Ib34cb3497bc2935a27622b5f5b187e1e315c8e46
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: https://github.com/dart-lang/sdk/issues/34152
Reviewed-on: https://dart-review.googlesource.com/c/90900
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2019-01-24 01:01:45 +00:00
Konstantin Shcheglov
5dab28f27f
Issue 34152. Verify file paths and report INVALID_FILE_PATH_FORMAT.
...
R=brianwilkerson@google.com , paulberry@google.com
Bug: https://github.com/dart-lang/sdk/issues/34152
Change-Id: I4a5f3634c342fbcfb3bf39c060cc658d87306312
Reviewed-on: https://dart-review.googlesource.com/c/90840
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2019-01-23 22:11:17 +00:00
Brian Wilkerson
47e988b781
Clean up the remaining copyright notices in analysis_server
...
Change-Id: Iee3110f92ab0f24312ddd1eff407d2229f895321
Reviewed-on: https://dart-review.googlesource.com/c/89101
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2019-01-11 15:38:56 +00:00
Konstantin Shcheglov
9ec260fd8e
Change completion tests to work in /home/test/.
...
Some completion tests (overrides) are valid when we make ChangeWorkspace
changes, because /completionTest.dart is not in /home/test. So, for
consistency I'm changing all tests to work with files in /home/test.
R=brianwilkerson@google.com
Change-Id: I050eedaf8da0aa47cdbc2d80195afa2ee23cdd01
Reviewed-on: https://dart-review.googlesource.com/c/87301
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-12-14 15:42:24 +00:00
Konstantin Shcheglov
c843a4fdbd
Replace resourceProvider.convertPath() with just convertPath() where possible.
...
R=brianwilkerson@google.com
Change-Id: I80c349b0ed9092e455ca2d811f5828765361ffc7
Reviewed-on: https://dart-review.googlesource.com/c/82163
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-10-30 23:55:26 +00:00
Danny Tuppeny
be39eacf00
Rename convertPathForImport -> convertAbsolutePathToUri
...
Also remove any calls that aren't required. The function still works if you pass it a relative path (for convenience, if you have a variable) but it's not required for relative paths.
Change-Id: I567e098f5956a7c2b5fe2d6d7d7fb16a263a72cc
Reviewed-on: https://dart-review.googlesource.com/c/79025
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Danny Tuppeny <dantup@google.com >
2018-10-10 16:03:58 +00:00
Dan Rubel
07a1f233f8
Improve parser recover to fix more code completion tests
...
Change-Id: I7bb03e18043b4951da7b63ffc146b6e7486f7e42
Reviewed-on: https://dart-review.googlesource.com/75601
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Dan Rubel <danrubel@google.com >
2018-09-20 17:00:41 +00:00
danrubel
fa0b38b45d
Fix some constructor initializer code completion situations
...
Change-Id: Ibbe079d79889846e34ab98ccdc11ef6fcc788654
Reviewed-on: https://dart-review.googlesource.com/75600
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Dan Rubel <danrubel@google.com >
2018-09-20 16:30:38 +00:00
Konstantin Shcheglov
1f52372bfa
Remove CFE integration from analyzer, analysis_server, and analyzer_cli.
...
AnalysisDriverResolutionTest is partially updated, about 30 failing
tests added. I will get back to it in a following CL, it is not
directly CFE integration, but updated understanding how we want to
resolve. For example we don't need types for non-expression identifiers.
Change-Id: I3daddbb6c66ffad7a726f3313a1199fd7387aa04
Reviewed-on: https://dart-review.googlesource.com/71883
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-08-29 13:46:45 +00:00
Janice Collins
f40ff153a9
Enable --use-fasta-parser with the analyzer by default.
...
Based on Devon's change at:
https://dart-review.googlesource.com/c/sdk/+/67090
Change-Id: I80b7943826e248bf37d9bbbb769330d24b0dd6ae
Reviewed-on: https://dart-review.googlesource.com/70160
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Devon Carew <devoncarew@google.com >
Commit-Queue: Janice Collins <jcollins@google.com >
2018-08-28 19:29:17 +00:00
Brian Wilkerson
f625490b09
Attempt to fix failures on the windows bot
...
Change-Id: I5fcda7cc11979dcde7948ffa4cfa53a5ee4e07e2
Reviewed-on: https://dart-review.googlesource.com/68162
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2018-08-02 19:16:04 +00:00
Brian Wilkerson
ea0468dff4
Fork more server tests to run under CFE
...
Change-Id: I7addca0b708e0b0dbb28e60619ea0bc2c20711af
Reviewed-on: https://dart-review.googlesource.com/68001
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2018-08-02 12:39:46 +00:00
danrubel
c738ae06b5
Revise recovery of ".as" and ".is" in fasta parser
...
Change-Id: Id7524d61682ac8ceac419e388ae02bb23cc63e63
Reviewed-on: https://dart-review.googlesource.com/66420
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Dan Rubel <danrubel@google.com >
2018-07-24 18:52:08 +00:00
Konstantin Shcheglov
757ef3979c
Revert "Revert "Revert "Don't do implicit new/const code generation with --preview-dart-2 enabled."""
...
This reverts commit 4089111540 .
R=brianwilkerson@google.com
Change-Id: I66297466f8baafe6e070acbcb1776b41f3d9fedc
Reviewed-on: https://dart-review.googlesource.com/55506
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-05-16 19:43:22 +00:00
Konstantin Shcheglov
4089111540
Revert "Revert "Don't do implicit new/const code generation with --preview-dart-2 enabled.""
...
This reverts commit e5ed23fdb5 .
R=brianwilkerson@google.com
Change-Id: Ida33856e965f06f773025f3c625d6ab3bace80a8
Reviewed-on: https://dart-review.googlesource.com/49280
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-04-03 22:29:09 +00:00
Konstantin Shcheglov
e5ed23fdb5
Revert "Don't do implicit new/const code generation with --preview-dart-2 enabled."
...
This reverts commit a1e4d8e0bf .
Reason for revert: <INSERT REASONING HERE>
Original change's description:
> Don't do implicit new/const code generation with --preview-dart-2 enabled.
>
> R=brianwilkerson@google.com , devoncarew@google.com
>
> Change-Id: I8a96a5ccceae57c3ed5c1f2e0fd4897a7e99df03
> Reviewed-on: https://dart-review.googlesource.com/48883
> Reviewed-by: Devon Carew <devoncarew@google.com >
> Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
> Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
TBR=devoncarew@google.com ,scheglov@google.com ,brianwilkerson@google.com
Change-Id: Ie3acf0794ed7b8264682e29aaa4bc1516fce6981
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://dart-review.googlesource.com/48900
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-03-30 19:24:46 +00:00
Konstantin Shcheglov
a1e4d8e0bf
Don't do implicit new/const code generation with --preview-dart-2 enabled.
...
R=brianwilkerson@google.com , devoncarew@google.com
Change-Id: I8a96a5ccceae57c3ed5c1f2e0fd4897a7e99df03
Reviewed-on: https://dart-review.googlesource.com/48883
Reviewed-by: Devon Carew <devoncarew@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-03-30 18:07:25 +00:00
Konstantin Shcheglov
50ba330a04
Fix for suggesting both class and its default constructor.
...
R=brianwilkerson@google.com , devoncarew@google.com
Bug: https://github.com/dart-lang/sdk/issues/32456
Change-Id: Ie4d8b38ad78b1d8ac72f95e71ec29f081d9a9ee8
Reviewed-on: https://dart-review.googlesource.com/45584
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Commit-Queue: Konstantin Shcheglov <scheglov@google.com >
2018-03-08 07:27:46 +00:00
Danny Tuppeny
7ca10a7adf
Fix file completion for absolute paths on Windows + related tests
...
Bug: https://github.com/dart-lang/sdk/issues/32226
Bug: https://github.com/dart-lang/sdk/issues/32277
Change-Id: Ie78423dc4a99efd25976b49ec7642362ed61a3c6
Reviewed-on: https://dart-review.googlesource.com/43961
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Dan Rubel <danrubel@google.com >
Commit-Queue: Danny Tuppeny <danny@tuppeny.com >
2018-02-27 17:20:49 +00:00
Danny Tuppeny
af527dd769
Fix some CompletionDomainHandlerTest tests on Windows
...
Bug: https://github.com/dart-lang/sdk/issues/32226
Change-Id: If6d0568d0de2268157c916267a0120c5b4295951
Reviewed-on: https://dart-review.googlesource.com/43666
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
Reviewed-by: Brian Wilkerson <brianwilkerson@google.com >
2018-02-26 15:53:37 +00:00
Paul Berry
105b170ddb
Roll package test to 0.12.29+1 and stack_trace to 1.9.0
...
This required some changes to analysis_server, since analysis_server
used to have its own version of pumpEventQueue(). Since
pumpEventQueue() is now provided by the test package, I've removed
analysis_server's version, and I've updated some of the call sites to
pass in "times: 5000" to replicate the old analysis_server behavior.
This also required some changes to analyzer, since the fail() method
is now marked as @alwaysThrows, so no code may follow it without
producing a dead code hint.
Change-Id: Ie5ef3a5cc685c18da02de699e59f63f3bb8865f7
Reviewed-on: https://dart-review.googlesource.com/32683
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Paul Berry <paulberry@google.com >
2018-01-07 14:22:23 +00:00
Brian Wilkerson
1d8a5d77c1
Convert more tests to use ResourceProviderMixin
...
Change-Id: Ia4cce51e33c79c82a989bfda9b8303dfaa72e103
Reviewed-on: https://dart-review.googlesource.com/31880
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
Commit-Queue: Brian Wilkerson <brianwilkerson@google.com >
2018-01-02 00:47:34 +00:00
Brian Wilkerson
b3439aa20b
Guard against broken code (issue 31023)
...
Change-Id: I9f53abb1257a3ffc86dc4bf46e2591c7f936d1fe
Reviewed-on: https://dart-review.googlesource.com/11940
Reviewed-by: Konstantin Shcheglov <scheglov@google.com >
2017-10-06 17:28:04 +00:00
Konstantin Shcheglov
00d5012906
Format analyzer, analysis_server, analyzer_plugin, front_end and kernel with the latest dartfmt.
...
...instead of mixing formatting with actual changes in many CLs.
R=ahe@google.com , paulberry@google.com , sigmund@google.com
BUG=
Review-Url: https://codereview.chromium.org/2975253002 .
2017-07-13 16:28:18 -07:00
Max Kim
311dd0bb0c
Modify autocompletion test case to work with new feature added
...
Request offset and Length of plugin response must line-up if main Dart autocompletion has suggestions already.
BUG=
R=brianwilkerson@google.com
Review-Url: https://codereview.chromium.org/2913903002 .
2017-05-30 17:14:48 -07:00
Brian Wilkerson
013411c10b
Allow plugins to provide completions for non-dart files
...
R=maxkim@google.com , scheglov@google.com
Review-Url: https://codereview.chromium.org/2910463002 .
2017-05-25 10:53:07 -07:00
Brian Wilkerson
7e11a13cf5
Add requestTime to responses
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2890163004 .
2017-05-18 10:32:47 -07:00
Brian Wilkerson
fb982f5476
Make server use the common protocol classes
...
R=danrubel@google.com
Review-Url: https://codereview.chromium.org/2879273002 .
2017-05-15 09:35:46 -07:00
Brian Wilkerson
27f9e5e4ce
Reverse the sense of the flag to make it easier to find test that need to be converted
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2884593003 .
2017-05-15 08:40:40 -07:00
Brian Wilkerson
3085734ef6
Generate common types into a separate library
...
R=danrubel@google.com
Review-Url: https://codereview.chromium.org/2880443006 .
2017-05-13 08:12:14 -07:00
danrubel
98825b4918
improve code completion abort request tests
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2876793006 .
2017-05-12 13:28:39 -07:00
danrubel
66bb2d618e
Remove unused analysisContext from completion request and contributors
...
Now that the analysis server uses the new analysis driver,
the CompletionRequest analysisContext field is always null.
This change removes that field and much of the unused code.
R=brianwilkerson@google.com , pquitslund@google.com
Review-Url: https://codereview.chromium.org/2877653002 .
2017-05-11 09:38:50 -07:00
Brian Wilkerson
3b2c3ae5b2
Add support for built-in plugins
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2874803003 .
2017-05-10 13:31:20 -07:00
Brian Wilkerson
2a4772a537
Remove unnecessary tests
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2868233003 .
2017-05-10 09:15:36 -07:00
danrubel
eb15a4c7c9
add constructor initializer completions
...
R=pquitslund@google.com
Review-Url: https://codereview.chromium.org/2869653002 .
2017-05-08 05:52:12 -07:00
Brian Wilkerson
e55812a3f2
Unify the server and plugin versions of the generators
...
R=devoncarew@google.com
Review-Url: https://codereview.chromium.org/2844273003 .
2017-04-28 07:46:29 -07:00
Brian Wilkerson
d98d672c16
Add completion support for plugins.
...
R=scheglov@google.com
Review-Url: https://codereview.chromium.org/2842243003 .
2017-04-27 10:26:46 -07:00
danrubel
02adcc9614
suggest catch and finally keywords
...
After a try block that does not have a "catch" block,
suggest the "catch" keyword and nothing else.
After a "catch" block, suggest the "finally" keyword.
Fix https://github.com/dart-lang/sdk/issues/27560
R=brianwilkerson@google.com
Review-Url: https://codereview.chromium.org/2662973007 .
2017-02-06 12:57:57 -05:00
Dan Rubel
f33c3c1676
complete named params in constructors
...
This add completion suggestions for named parameters
in constructors and factories, and prevents other suggestions
such as type names, identifiers, etc when they are not appropriate.
R=brianwilkerson@google.com
Review-Url: https://codereview.chromium.org/2671533002 .
2017-02-01 14:36:41 -05:00
Konstantin Shcheglov
fc30904a39
Completion with the new analysis driver.
...
It works for top-levels, fields, locals, prefixed expressions.
Integration is not the most efficient - we resolve the full unit.
It works fine for files with about 1000 lines, about 50-70 ms.
We could slightly improve timing if we prioritize completion over
navigation and highlight notifications, which are currently prepared
and sent before completion.
In giant files like src/dart/element/element.dart, about 8500 lines,
it takes about 400 ms from typing to receiving completion. The theoretical
bottom bound for such files is about 70 ms - time that it required to
parse, create unlinked bundle, ensure that the API signature is the
same, load linked bundles and prepare to resynthesize. On top of this
goes any time required to resolve a single method and completion itself.
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/2478963002 .
2016-11-06 10:45:46 -08:00
Konstantin Shcheglov
05a86a7495
Remove 'initializeTestEnvironment' from 'analysis_server'.
...
Also fixes the server_options_test.dart:22 test broken in https://codereview.chromium.org/2394683006/
R=paulberry@google.com , brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2402483002 .
2016-10-06 10:26:17 -07:00
Konstantin Shcheglov
de4d8b3a78
Switch analysis_server to use 'package:test'.
...
I'm changing DEPS in the corresponding analyzer CL.
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org/2394683006 .
2016-10-06 08:47:15 -07:00
Konstantin Shcheglov
f8f4228728
Revert "Flush AST results for source outside of the analysis roots."
...
This reverts commit b115309531 .
Revert "Use FlushTargetFilter to pre-filter targets before checking their results."
This reverts commit 2e24662c06 .
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org/2298043002 .
2016-08-30 19:55:10 -07:00