| Index: pkg/analyzer/test/src/dart/analysis/index_test.dart
|
| diff --git a/pkg/analyzer/test/src/dart/analysis/index_test.dart b/pkg/analyzer/test/src/dart/analysis/index_test.dart
|
| index 8c544c72d7a8789bb03be97d7edffb596aad6771..04048636e3235c44ebea7f5b9cf1798b6aea1137 100644
|
| --- a/pkg/analyzer/test/src/dart/analysis/index_test.dart
|
| +++ b/pkg/analyzer/test/src/dart/analysis/index_test.dart
|
| @@ -7,7 +7,6 @@ import 'dart:convert';
|
|
|
| import 'package:analyzer/dart/ast/ast.dart';
|
| import 'package:analyzer/dart/element/element.dart';
|
| -import 'package:analyzer/dart/element/visitor.dart';
|
| import 'package:analyzer/src/dart/analysis/driver.dart';
|
| import 'package:analyzer/src/dart/analysis/index.dart';
|
| import 'package:analyzer/src/summary/format.dart';
|
| @@ -23,28 +22,6 @@ main() {
|
| });
|
| }
|
|
|
| -/**
|
| - * Finds an [Element] with the given [name].
|
| - */
|
| -Element findChildElement(Element root, String name, [ElementKind kind]) {
|
| - Element result = null;
|
| - root.accept(new _ElementVisitorFunctionWrapper((Element element) {
|
| - if (element.name != name) {
|
| - return;
|
| - }
|
| - if (kind != null && element.kind != kind) {
|
| - return;
|
| - }
|
| - result = element;
|
| - }));
|
| - return result;
|
| -}
|
| -
|
| -/**
|
| - * A function to be called for every [Element].
|
| - */
|
| -typedef void _ElementVisitorFunction(Element element);
|
| -
|
| class ExpectedLocation {
|
| final CompilationUnitElement unitElement;
|
| final int offset;
|
| @@ -1210,20 +1187,6 @@ class _ElementIndexAssert {
|
| }
|
| }
|
|
|
| -/**
|
| - * Wraps an [_ElementVisitorFunction] into a [GeneralizingElementVisitor].
|
| - */
|
| -class _ElementVisitorFunctionWrapper extends GeneralizingElementVisitor {
|
| - final _ElementVisitorFunction function;
|
| -
|
| - _ElementVisitorFunctionWrapper(this.function);
|
| -
|
| - visitElement(Element element) {
|
| - function(element);
|
| - super.visitElement(element);
|
| - }
|
| -}
|
| -
|
| class _NameIndexAssert {
|
| final IndexTest test;
|
| final String name;
|
|
|