anchor.diff:    return _metadataFromAncestry(node.parent);
   }
   
  -List<Annotation> _metadataWithWorkaround(
  -    AstNode node, Element originalElement) {
  -  var resolvedMetadata = _metadataFromAncestry(node);
  -
  -  // TODO(b/124524319): Remove this check when the Analyzer is fixed.
  -  if (resolvedMetadata.isEmpty &&
  -      originalElement is ParameterElement &&
  -      node is ConstructorDeclaration) {
  -    return null;
  -  }
  -  return resolvedMetadata;
  -}
  -
   class ErrorMessageForAnnotation extends AsyncBuildError {
     final IndexedAnnotation indexedAnnotation;
   
  
positive.code:     ElementDeclarationResult result;
      try {
        result = await _resolvedClassResult(
            resolver, indexedAnnotation.element, toString());
      } on BuildError catch (buildError) {
        return buildError;
      }
  
      var resolvedMetadata =
          _metadataWithWorkaround(result.node, indexedAnnotation.element);
  
      if (resolvedMetadata == null) {
        return BuildError.forElement(indexedAnnotation.element, toString());
  
negative.code:       );
      }
  
      var resolvedMetadata = _metadataFromAncestry(result.node);
  
      if (resolvedMetadata == null) {
        return BuildError.forElement(indexedAnnotation.element, toString());
  