improve error messages

This commit is contained in:
Jonathan Shook 2022-06-16 15:13:29 -05:00
parent 64da6df3e8
commit 3a90c0512c

View File

@ -110,7 +110,8 @@ public class Annotators {
if (!type.isAnnotationPresent(Service.class)) {
throw new RuntimeException(
"Annotator services must be annotated with distinct selectors\n" +
"such as @Service(Annotator.class,selector=\"myimpl42\")"
"such as @Service(Annotator.class,selector=\"myimpl42\")" +
" but " + provider.type().getCanonicalName() + " had none."
);
}
Service service = type.getAnnotation(Service.class);