Skip to content

Commit

Permalink
More fixes for module mode
Browse files Browse the repository at this point in the history
  • Loading branch information
dmlloyd committed Jul 5, 2024
1 parent 0dca8ee commit 8a076de
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion annotations/src/main/java/module-info.java
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
module org.jboss.logging.annotations {
requires static org.jboss.logging;
requires org.jboss.logging;
exports org.jboss.logging.annotations;
}
1 change: 0 additions & 1 deletion processor/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,6 @@
<dependency>
<groupId>org.jboss.logging</groupId>
<artifactId>jboss-logging</artifactId>
<scope>provided</scope>
</dependency>

<dependency>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -143,8 +143,9 @@ private AptMessageInterface(final TypeElement interfaceElement, final Processing
// Determine the type for the generated annotation
final ModuleElement moduleElement = processingEnv.getElementUtils()
.getModuleElement(Generated.class.getModule().getName());
this.generatedAnnotation = processingEnv.getElementUtils().getTypeElement(moduleElement,
Generated.class.getName());
this.generatedAnnotation = moduleElement == null
? processingEnv.getElementUtils().getTypeElement(Generated.class.getName())
: processingEnv.getElementUtils().getTypeElement(moduleElement, Generated.class.getName());
} else {
this.generatedAnnotation = null;
}
Expand Down

0 comments on commit 8a076de

Please sign in to comment.