brianwilkerson@google.com
44c2892f6f
Initial support for execution domain
...
R=paulberry@google.com
Review URL: https://codereview.chromium.org//544273003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39974 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-08 16:21:16 +00:00
brianwilkerson@google.com
29341b4e5e
Rename debug domain to execution
...
R=paulberry@google.com
Review URL: https://codereview.chromium.org//547753002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39942 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-06 02:43:12 +00:00
scheglov@google.com
897ba068ee
Fix for no-op assist proposals.
...
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org//548523004
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39931 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-05 21:09:01 +00:00
paulberry@google.com
77a6daa667
Add error condition INVALID_OVERLAY_CHANGE to analysis server.
...
R=danrubel@google.com
Review URL: https://codereview.chromium.org//545323002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39925 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-05 19:23:55 +00:00
scheglov@google.com
3661df5b0e
Include additional information into RenameFeedback.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//545943003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39918 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-05 16:39:15 +00:00
scheglov@google.com
67cd1ab0e2
Decode RefactoringFeedback automatically.
...
The implementation is pretty ugly though.
1. I have to add Response into ResponseDecoder.
2. I have to hack EditGetRefactoringParams.fromRequest generation to feel the "id to kind" map.
It would be easier if we decided to return 'kind' in responses.
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org//541823004
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39887 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-04 21:13:24 +00:00
scheglov@google.com
5033317a13
Split channels library.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//544693002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39881 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-04 17:53:16 +00:00
scheglov@google.com
3ddecb8c64
Use typed RefactoringOptions in the Dart version of the protocol.
...
R=jwren@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org//537733002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39875 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-04 16:21:08 +00:00
paulberry@google.com
9279b9fe81
Fix error handling in analysis.getError.
...
Analysis.getError now has the following behaviors:
- If the file in question does not exist, or is not subject to
analysis, a new error called GET_ERRORS_INVALID_FILE is generated.
- If the server's internal state (the set of active analysis contexts)
changes while the query is in process, the query is transparently
restarted; the client no longer receives a GET_ERRORS_ERROR error.
R=scheglov@google.com
Review URL: https://codereview.chromium.org//532403002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39871 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-04 14:34:43 +00:00
paulberry@google.com
245168938e
Merge analysis server's mocks.dart and mocks2.dart into one file.
...
There were competing implementations of MockAnalysisContext and
MockSource, but one of the implementations was only used in one place
(analysis_server_test.dart), so it's been switched over to use the
other implementation.
R=scheglov@google.com
Review URL: https://codereview.chromium.org//532333002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39826 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-03 19:45:42 +00:00
scheglov@google.com
44473cf553
Integrate INLINE_LOCAL_VARIABLE into the server.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//540503002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39824 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-03 19:23:37 +00:00
scheglov@google.com
43b0e2d584
Use unit + offset as 'Inline Local' arguments.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//533273003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39821 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-03 18:45:18 +00:00
scheglov@google.com
dfeccd520d
Integrate INLINE_METHOD into the server.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//538583002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39816 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-03 18:32:36 +00:00
paulberry@google.com
8d8ee25cff
Merge analysis_testing package into analysis_server.
...
Note that analysis_server already contains a file test/mocks.dart, so
the mocks.dart file from analysis_testing has been imported as
test/mocks2.dart. I will merge these two into a single file in a
future CL.
R=scheglov@google.com
Review URL: https://codereview.chromium.org//533243002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39814 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-03 18:11:42 +00:00
scheglov@google.com
063e6cc00f
Fix for NPE in the server.
...
I think that is the same NPE we saw in both Dart and Java last week.
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org//529313002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39809 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-03 14:55:32 +00:00
scheglov@google.com
47fe46e1a6
Integrate EXTRACT_METHOD refactoring into the server.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//534123002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39808 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-03 14:54:16 +00:00
danrubel@google.com
216602d57a
return correct replacementOffset and replacementLength
...
BUG=
R=jwren@google.com
Review URL: https://codereview.chromium.org//536593002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39789 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-03 00:55:40 +00:00
danrubel@google.com
efb4c758f8
improve keyword suggestions when completing partial keyword
...
BUG=
R=jwren@google.com
Review URL: https://codereview.chromium.org//531243002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39780 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 21:54:56 +00:00
scheglov@google.com
df574c6e2c
Test for 'search.findElementReferences' for the case when there is no element.
...
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org//536563002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39779 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 21:54:19 +00:00
scheglov@google.com
4213f465fe
Fix for 'returnType' when extract a method with a single expression.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//533913002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39778 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 21:51:21 +00:00
paulberry@google.com
703df31e12
Rename ExecutableFile.offset to ExecutableFile.kind and fix documentation.
...
R=scheglov@google.com
Review URL: https://codereview.chromium.org//528053002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39774 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 20:13:03 +00:00
paulberry@google.com
33b4cc89c0
Make findElementReferences' "id" result optional.
...
R=jwren@google.com
Review URL: https://codereview.chromium.org//529123002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39773 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 20:10:59 +00:00
scheglov@google.com
b7189ea678
New analyzer snapshot.
...
We compute the parameter element for 'object.field = 42' now, so:
1. We can stop doing it in InlineMethodRefactoring.
2. We need to update the corresponding hover integration test.
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org//535543003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39772 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 20:10:47 +00:00
paulberry@google.com
d092a96981
Clarify type names in analysis server API.
...
The following types are renamed:
- ErrorFixes -> AnalysisErrorFixes
- ErrorSeverity -> AnalysisErrorSeverity
- ErrorType -> AnalysisErrorType
This clarifies that the types have to do with the
errors/warnings/hints generated by the analysis of user code, as
opposed to analysis server protocol errors.
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org//531153002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39770 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 19:54:03 +00:00
scheglov@google.com
43e1872038
Impements 'names', 'offsets' and 'lengths' for ExtractMethodRefactoring.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//530123002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39768 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 19:35:48 +00:00
paulberry@google.com
a239950909
Rename Error to RequestError in analysis server API.
...
Also, use the code-generated RequestError class in place of the old
handwritten RequestError class.
R=jwren@google.com
Review URL: https://codereview.chromium.org//530583004
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39760 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 18:20:47 +00:00
paulberry@google.com
ba9c0c689b
Use a more precise type for "object" in analysis server API.
...
Previously, we translated "object" in the API to the dart type
"Object". But this is not correct, since in the API when we say
"object" we mean "JSON object", which corresponds to a Dart Map.
Using a more precise type exposed some bugs in our refactoring
implementation, where we were forgetting to convert objects to and
from JSON.
R=scheglov@google.com
Review URL: https://codereview.chromium.org//530033002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39757 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 17:46:02 +00:00
scheglov@google.com
d8b6298631
Drop the 'occurrences' field from the EXTRACT_METHOD refactoring feedback.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//533743002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39756 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 16:59:23 +00:00
scheglov@google.com
209abb70f4
Integrate EXTRACT_LOCAL_VARIABLE into the server.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//526183002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39747 260f80e4-7a28-3924-810f-c04153c831b5
2014-09-02 15:00:45 +00:00
scheglov@google.com
3d5ea37050
'Inline Method' refactoring.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//526583002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39719 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-31 16:43:43 +00:00
paulberry@google.com
3123e48d29
In the analysis server API, change RequestError.code to an enum.
...
Some of the error codes that were previously defined are no longer
used, so those have been removed. The enum reflects the set of errors
that are currently in use.
R=brianwilkerson@google.com , scheglov@google.com
Review URL: https://codereview.chromium.org//513853002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39689 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-29 07:30:43 +00:00
scheglov@google.com
ca869c6d27
Tweaks for refactoring tests.
...
Mostly the push of 'assertSuccessfulRefactoring' into abstract RefactoringTest.
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//516673002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39658 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-28 15:15:17 +00:00
scheglov@google.com
2a7e871aab
'Inline Local' refactoring.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//515733002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39656 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-28 15:10:11 +00:00
paulberry@google.com
f556420f97
Rename some bools in the analysis server API.
...
R=brianwilkerson@google.com , jwren@google.com
Review URL: https://codereview.chromium.org//508203002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39604 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-27 16:39:49 +00:00
scheglov@google.com
df2dc27f50
Parameters and validation for the 'Extract Method' refactoring.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//506753002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39538 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-26 05:48:15 +00:00
scheglov@google.com
d197a2cded
Extract 'toJson' in TH test.
...
R=paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org//501043002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39526 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-25 19:11:17 +00:00
scheglov@google.com
96a0c295ac
Initial 'Extract Method' refactoring implementation.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//498763003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39520 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-25 15:38:00 +00:00
paulberry@google.com
0c0fd777a6
Finish modifying analysis server to make use of code generation.
...
Generated code is used to produce the response to these requests:
- analysis.updateOptions
- analysis.updateContent
- analysis.setSubscriptions
- analysis.setPriorityFiles
- analysis.setAnalysisRoots
- server.shutdown
- server.setSubscriptions
Generated code is used to produce these requests:
- server.shutdown
- server.getVersion
- server.shutdown
- server.connected
Generated code is used to produce these notifications:
- completion.results
- analysis.overrides
- analysis.outline
- analysis.occurrences
Generated code is used to decode these notifications:
- server.status
In addition, some dead code was removed, the 'protocol.dart' and
'protocol2.dart' files were combined, and the fields Response.result,
Request.params, and Notification.params were made private (to
encourage future use of the generated code). Also, some overly
verbose import statements were cleaned up by using "hide" rather than
"show".
R=danrubel@google.com
Review URL: https://codereview.chromium.org//506433002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39516 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-25 10:48:16 +00:00
scheglov@google.com
e16a9dfe84
Send RenameFeedback.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//501843002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39514 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-25 05:07:43 +00:00
paulberry@google.com
e18327f317
Make more use of generated code in analysis server.
...
The following generated classes are now used:
- CompletionRelevance
- CompletionSuggestion
- CompletionSuggestionKind
- ErrorFixes
- HighlightRegion
- HighlightRegionType
- HoverInformation
- LinkedEditGroup
- LinkedEditSuggestion
- LinkedEditSuggestionKind
- SourceChange
Generated code is used to produce these notifications:
- analysis.errors
- analysis.highlights
- analysis.navigation
- search.results
- server.error
- server.status
Generated code is used to produce the response to these requests:
- analysis.getErrors
- analysis.getHover
- edit.getAssists
- edit.getFixes
- server.getVersion
Generated code is used to handle these notifications in unit testing:
- analysis.highlights
- analysis.navigation
In addition, these methods have been removed, since they are no longer
needed:
- Notification.getParameter
- Result.setEmptyResult
- Result.setResult
R=brianwilkerson@google.com
Review URL: https://codereview.chromium.org//497393002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39511 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-24 08:39:41 +00:00
paulberry@google.com
665da3d948
Make certain generated constructor parameters optional.
...
The following constructor parameters are optional as a convenience to
callers. They default to empty lists:
- SourceFileEdit.edits
- TypeHierarchyItem.interfaces
- TypeHierarchyItem.mixins
- TypeHierarchyItem.subclasses
R=scheglov@google.com
Review URL: https://codereview.chromium.org//499073002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39510 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-23 23:56:24 +00:00
scheglov@google.com
5dda914674
Implement 'edit.getRefactoring' for rename refactoring.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//499723002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39509 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-23 21:14:25 +00:00
paulberry@google.com
10fdb7677a
Change analysis server protocol to omit empty lists when optional.
...
For object fields of type List that are marked as optional, FromJson
code automatically populates the data structure with an empty list
when the field is omitted. ToJson code automatically omits the field
when its value is an empty list.
R=brianwilkerson@google.com , scheglov@google.com
Review URL: https://codereview.chromium.org//482573004
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39507 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-23 18:03:34 +00:00
scheglov@google.com
39a38da0e7
Move Location factories and RefactoringProblemSeverity.max into the generated classes.
...
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org//462403005
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39499 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-22 17:27:19 +00:00
scheglov@google.com
71d70c2de3
Rename 'getRefactoring.return.status' to 'problems'.
...
It is a list, and we name lists with plurals.
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//495273002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39495 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-22 14:47:30 +00:00
scheglov@google.com
fd11028816
Make RefactoringStatus a collection of generated RefactoringProblems.
...
R=brianwilkerson@google.com , paulberry@google.com
BUG=
Review URL: https://codereview.chromium.org//485083004
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39494 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-22 14:45:33 +00:00
scheglov@google.com
436a6b725b
Make RefactoringProblem.location optional.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//496113002
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39476 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-21 21:44:08 +00:00
scheglov@google.com
47b813e4ec
Rename 'kindId' to 'kind' in 'edit.getRefactoring'.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//473763003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39474 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-21 20:57:14 +00:00
paulberry@google.com
caf0592503
Make more use of generated code in analysis server.
...
The following generated classes are now used:
- Element
- Location
- Occurrences
- Outline
- OverriddenMember
- Override
- Position
- SearchResult
- SearchResultKind
- SourceFileEdit
- TypeHierarchyItem
Generated code is used to produce the responses to these requests:
- completion.getSuggestions
- search.findElementReferences
- search.findMemberDeclarations
- search.findMemberReferences
- search.findTopLevelDeclarations
- search.getTypeHierarchy
Generated code is used to handle these notifications in unit testing:
- analysis.navigation
- analysis.occurrences
- analysis.outline
- analysis.overrides
- search.results
In addition, we no longer bother to test the JSON conversion code on
AnalysisError, since it is code generated.
R=scheglov@google.com
Review URL: https://codereview.chromium.org//479683005
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39470 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-21 20:04:06 +00:00
scheglov@google.com
e666722007
Make EXTRACT_LOCAL and EXTRACT_METHOD refactorings available when there is a selection.
...
R=brianwilkerson@google.com
BUG=
Review URL: https://codereview.chromium.org//490923003
git-svn-id: https://dart.googlecode.com/svn/branches/bleeding_edge/dart@39463 260f80e4-7a28-3924-810f-c04153c831b5
2014-08-21 17:43:22 +00:00