Skip to content

Commit d5ed9b3

Browse files
committed
Change RetentionPolicy to RUNTIME in NotNullByDefault annotation
Motivation: The NotNullByDefault annotation was originally set with a RetentionPolicy of CLASS, which means it is only available during compile-time. However, we want it to be available during runtime as well, so we can use it for null-checking in Kotlin. Modifications: Changed the RetentionPolicy of the NotNullByDefault annotation from CLASS to RUNTIME. Result: The NotNullByDefault annotation can now be used for null-checking in Kotlin during both compile-time and runtime.
1 parent 7aebe83 commit d5ed9b3

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/io/asyncer/r2dbc/mysql/internal/NotNullByDefault.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@
3737
*/
3838
@Documented
3939
@TypeQualifierDefault({ ElementType.METHOD, ElementType.PARAMETER })
40-
@Retention(RetentionPolicy.CLASS)
40+
@Retention(RetentionPolicy.RUNTIME)
4141
@Target(ElementType.PACKAGE)
4242
@NotNull
4343
public @interface NotNullByDefault {

0 commit comments

Comments
 (0)