anchor.diff:  //                time oracle is created. There should be a better way.
   typedef Workspace WsGetter();
   
  -/// Callback invoked with the file user selected to open.
  +/**
  + *  Callback invoked with the file user selected to open.
  + */
   typedef void FileOpener(File file);
   
  -/// Provides search [Suggestion]s for the top-level search box.
  -///
  -/// Currently searches by file name only.
  +/**
  + *  Provides search [Suggestion]s for the top-level search box.
  + *  Currently searches by file name only.
  + */
   class SearchOracle implements SuggestOracle {
     final WsGetter _wsGetter;
     final FileOpener _fileOpener;
  -  final int _limitCount;
  +  final int _maxResultsCount;
   
  -  SearchOracle(this._wsGetter, this._fileOpener, [this._limitCount=100]);
  +  SearchOracle(this._wsGetter, this._fileOpener, [this._maxResultsCount]);
   
     Stream<List<Suggestion>> getSuggestions(String text) {
       if (text == null || text.trim().isEmpty) {
  
positive.code:     }
      text = _cleanse(text);
      // TODO(yjbanov): this is the most naive algorithm ever. We need a way to
      //                index the sources and run the search incrementally and
      //                preferably in a separate isolate, and test on a large
      //                project.
      var suggestions = _wsGetter()
          .traverse()
          .where((res) => res is File && _matches(res.name, text))
          .take(_limitCount)
          .map((res) => _makeSuggestionFromResource(res))
          .toList(growable: false);
      return new Stream.fromIterable([suggestions]);
    }
  
    String _cleanse(String s) =>
        s.trim().replaceAll('[_-]', '').toLowerCase();
  
    bool _matches(String string, String searchText) =>
        string != null && _cleanse(string).contains(searchText);
  
    Suggestion _makeSuggestionFromResource(Resource res) {
  
negative.code:         details: res.parent.path,
          onSelected: () => _fileOpener(res));
    }
  
    static int _compareSuggestions(Suggestion a, Suggestion b) {
      int res = a.label.toLowerCase().compareTo(b.label.toLowerCase());
      if (res == 0) {
        res = a.details.toLowerCase().compareTo(b.details.toLowerCase());
      }
      return res;
    }
  }
  