Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1032)

Unified Diff: pkg/analysis_services/lib/correction/change.dart

Issue 418373002: More tests for creating undefined methods and functions. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | pkg/analysis_services/lib/src/correction/fix.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/analysis_services/lib/correction/change.dart
diff --git a/pkg/analysis_services/lib/correction/change.dart b/pkg/analysis_services/lib/correction/change.dart
index 2135d133a0da083490a3e2f2f5f603a616127aab..d4073e963fa4490868dafe06667afb691ca2cb06 100644
--- a/pkg/analysis_services/lib/correction/change.dart
+++ b/pkg/analysis_services/lib/correction/change.dart
@@ -193,10 +193,11 @@ class FileEdit implements HasToJson {
class LinkedPositionGroup implements HasToJson {
final String id;
final List<Position> positions = <Position>[];
+ final List<String> proposals = <String>[];
LinkedPositionGroup(this.id);
- void add(Position position) {
+ void addPosition(Position position) {
if (positions.isNotEmpty && position.length != positions[0].length) {
throw new ArgumentError(
'All positions should have the same length. '
@@ -205,6 +206,10 @@ class LinkedPositionGroup implements HasToJson {
positions.add(position);
}
+ void addProposal(String proposal) {
+ proposals.add(proposal);
+ }
+
@override
Map<String, Object> toJson() {
return {
« no previous file with comments | « no previous file | pkg/analysis_services/lib/src/correction/fix.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698