getFieldAnnotation function
Implementation
ConstantReader? getFieldAnnotation(FieldElement field, Type type) {
final annot = typeChecker(
type,
).firstAnnotationOf(field, throwOnUnresolved: false);
if (annot != null) return ConstantReader(annot);
return null;
}