fix(transformer): Don't throw on annotations that don't match a descriptor.

Closes #3280
This commit is contained in:
Jacob MacDonald 2015-07-24 13:20:01 -07:00 committed by Tobias Bosch
parent 5b5de6662f
commit f575ba60fb
1 changed files with 1 additions and 3 deletions

View File

@ -84,9 +84,7 @@ class AnnotationMatcher extends ClassMatcherBase {
bool _implementsWithWarning(Annotation annotation, AssetId assetId,
List<ClassDescriptor> interfaces) {
ClassDescriptor descriptor = firstMatch(annotation.name, assetId);
if (descriptor == null) {
throw 'Unable to locate descriptor for ${annotation.name} in ${assetId}';
}
if (descriptor == null) return false;
return implements(descriptor, interfaces,
missingSuperClassWarning: 'Missing `custom_annotation` entry for `${descriptor.superClass}`.');
}