Skip to content

Commit 57e0356

Browse files
committed
no longer need to suppress deprecations
1 parent 8750a09 commit 57e0356

File tree

3 files changed

+0
-7
lines changed

3 files changed

+0
-7
lines changed

core/src/main/java/org/jruby/java/proxies/JavaProxy.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -145,7 +145,6 @@ public final Object dataGetStruct() {
145145
}
146146

147147
@Override
148-
@SuppressWarnings("deprecation")
149148
public final void dataWrapStruct(Object object) {
150149
if (object instanceof JavaProxy) {
151150
this.object = ((JavaProxy) object).object;

core/src/main/java/org/jruby/javasupport/JavaUtil.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -230,7 +230,6 @@ public static <T> T convertProcToInterface(ThreadContext context, RubyObject rub
230230
return convertProcToInterface(context, (RubyBasicObject) rubyObject, targetType);
231231
}
232232

233-
@SuppressWarnings("unchecked")
234233
public static <T> T convertProcToInterface(ThreadContext context, RubyBasicObject rubyObject, Class<T> targetType) {
235234
// Capture original class; we only detach the singleton for natural Proc instances
236235
RubyClass procClass = rubyObject.getMetaClass();
@@ -280,7 +279,6 @@ public static <T> NumericConverter<T> getNumericConverter(Class<T> target) {
280279
* @param object
281280
* @return true if the object is wrapping a Java object
282281
*/
283-
@SuppressWarnings("deprecation")
284282
public static boolean isJavaObject(final IRubyObject object) {
285283
return object instanceof JavaProxy;
286284
}
@@ -291,7 +289,6 @@ public static boolean isJavaObject(final IRubyObject object) {
291289
* @return Java object
292290
* @see JavaUtil#isJavaObject(IRubyObject)
293291
*/
294-
@SuppressWarnings("deprecation")
295292
public static <T> T unwrapJavaObject(final IRubyObject object) {
296293
return (T) ((JavaProxy) object).getObject();
297294
}
@@ -302,7 +299,6 @@ public static <T> T unwrapJavaObject(final IRubyObject object) {
302299
* @return java object or passed object
303300
* @see JavaUtil#isJavaObject(IRubyObject)
304301
*/
305-
@SuppressWarnings("deprecation")
306302
public static <T> T unwrapIfJavaObject(final IRubyObject object) {
307303
if ( object instanceof JavaProxy ) {
308304
return (T) ((JavaProxy) object).getObject();
@@ -1471,7 +1467,6 @@ public static IRubyObject java_to_primitive(IRubyObject recv, IRubyObject object
14711467
}
14721468

14731469
@Deprecated
1474-
@SuppressWarnings("deprecation")
14751470
public static IRubyObject primitive_to_java(IRubyObject recv, IRubyObject object, Block unusedBlock) {
14761471
var context = ((RubyObject) recv).getCurrentContext();
14771472
Object javaObject;

core/src/main/java/org/jruby/javasupport/ext/JavaLangReflect.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -412,7 +412,6 @@ private static Object unwrapJavaObject(final IRubyObject object) {
412412
return JavaUtil.unwrapJavaValue(object);
413413
}
414414

415-
@SuppressWarnings("deprecation")
416415
private static Object convertValueToJava(final java.lang.reflect.Field field, IRubyObject value) {
417416
return value.toJava(field.getType());
418417
}

0 commit comments

Comments
 (0)