You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I find that FormatAnnotationsStep works OK with annotations on fields/getters that follow the form mentioned in this note.
But I have started using records in my project and have code like this:
public record EnumsDto(
@JsonbProperty("external") @Valid@NullableExternalEnumexternal,
@JsonbProperty("externalLower") @Valid@NullableExternalLowerEnumexternalLower,
...
The above is the formatAnnotations() output.
But it should (if I understand things correctly) be:
public record EnumsDto(
@JsonbProperty("external")
@Valid@NullableExternalEnumexternal,
@JsonbProperty("externalLower")
@Valid@NullableExternalLowerEnumexternalLower,
...
But since there is no protection keyword (public/private) to separate the non-type annotations from the type-annotations, they all get merged into the same line by FormatAnnotationsStep.
I think this can be fixed simply by only stripping newlines from type-annotations.
And thus leaving them for unknown annotations (which does not happen now).
This is a breaking change that makes me nervous. If you can gate it behind a flag, then I can easily merge. If you can't, we need to consider the impact to existing users a bit. @mernst any thoughts?
I find that FormatAnnotationsStep works OK with annotations on fields/getters that follow the form mentioned in this note.
But I have started using records in my project and have code like this:
The above is the formatAnnotations() output.
But it should (if I understand things correctly) be:
But since there is no protection keyword (public/private) to separate the non-type annotations from the type-annotations, they all get merged into the same line by FormatAnnotationsStep.
This is observed with version Gradle Plugin v7.0.0.BETA4
The text was updated successfully, but these errors were encountered: