Skip to content

Commit

Permalink
Make the generated property private for @ContributingAnnotation
Browse files Browse the repository at this point in the history
There is no reason to expose the generated property on the compile classpath.
  • Loading branch information
vRallev committed Sep 24, 2024
1 parent db43da2 commit 86b3fd8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
### Changed

* **BREAKING CHANGE:** Enforce scope parameter on all `@Contributes*` annotations and stop using the kotlin-inject scope implicitly, see #36.
* Made the generated property when using `@ContributingAnnotation` private. There is no reason to expose the property on the compile classpath.

### Deprecated

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ internal class ContributingAnnotationProcessor(
.builder(
name = clazz.safeClassName.decapitalize(),
type = KClass::class.asClassName().parameterizedBy(clazz.toClassName()),
modifiers = setOf(KModifier.PUBLIC),
modifiers = setOf(KModifier.PRIVATE),
)
.initializer("%T::class", clazz.toClassName())
.addOriginatingKSFile(clazz.requireContainingFile())
Expand Down

0 comments on commit 86b3fd8

Please sign in to comment.