Skip to content

Commit 1d6e834

Browse files
radekdoulikjonpryor
authored andcommitted
[Java.Interop] Checked remaining disposed exception defects (#241)
Added them to the gendarme ignore list with an explanation.
1 parent 19379a3 commit 1d6e834

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

gendarme-ignore.txt

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -264,6 +264,7 @@ M: Java.Interop.JniType Java.Interop.JniType::GetSuperclass()
264264
M: System.Boolean Java.Interop.JniType::IsAssignableFrom(Java.Interop.JniType)
265265
M: System.Boolean Java.Interop.JniType::IsInstanceOfType(Java.Interop.JniObjectReference)
266266
M: System.Void Java.Interop.JniType::RegisterNativeMethods(Java.Interop.JniNativeMethodRegistration[])
267+
M: System.Void Java.Interop.JniType::RegisterWithRuntime()
267268
M: System.Void Java.Interop.JniType::UnregisterNativeMethods()
268269
M: Java.Interop.JniMethodInfo Java.Interop.JniType::GetConstructor(System.String)
269270
M: Java.Interop.JniMethodInfo Java.Interop.JniType::GetCachedConstructor(Java.Interop.JniMethodInfo&,System.String)
@@ -278,6 +279,13 @@ M: Java.Interop.JniMethodInfo Java.Interop.JniType::GetCachedInstanceMethod(Java
278279
M: Java.Interop.JniMethodInfo Java.Interop.JniType::GetStaticMethod(System.String,System.String)
279280
M: Java.Interop.JniMethodInfo Java.Interop.JniType::GetCachedStaticMethod(Java.Interop.JniMethodInfo&,System.String,System.String)
280281

282+
# do not check here to improve performance
283+
M: System.Void Java.Interop.JniArrayElements::CopyToJava()
284+
M: System.Int32 Java.Interop.JavaObjectArray`1::IndexOf(T)
285+
M: Java.Interop.JniArrayElements Java.Interop.JavaPrimitiveArray`1::GetElements()
286+
287+
# it doesn't make sense to check the disposed state here, as the JavaObject::Dispose(bool) doesn't do anything and neither the JavaArray nor JavaObjectArray override it
288+
M: System.Void Java.Interop.JavaObjectArray`1::set_Item(System.Int32,T)
281289

282290
R: Gendarme.Rules.Interoperability.MarshalBooleansInPInvokeDeclarationsRule
283291
# These aren't `bool`, they're `bool*`, which is a *huge* difference!

0 commit comments

Comments
 (0)