it_shall_not_named_`ignored`_ (#540)

This commit is contained in:
XenoAmess 2020-06-13 23:14:45 +08:00 committed by GitHub
parent 0eb4a8f87f
commit 29b87d5cea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -740,11 +740,11 @@ public static void removeFinalModifier(final Field field, final boolean forceAcc
}
}
}
} catch (final NoSuchFieldException | IllegalAccessException ignored) {
} catch (final NoSuchFieldException | IllegalAccessException e) {
if (SystemUtils.isJavaVersionAtLeast(JavaVersion.JAVA_12)) {
throw new UnsupportedOperationException(
"In java 12+ final cannot be removed.",
ignored
e
);
}
// else no exception is thrown because we can modify final.