Skip to content

Commit

Permalink
Showing 2 changed files with 6 additions and 2 deletions.
4 changes: 4 additions & 0 deletions tool/truffle-findbugs-exclude.xml
Original file line number Diff line number Diff line change
@@ -29,6 +29,10 @@
<Class name="org.jruby.truffle.nodes.exceptions.TopLevelRaiseHandler" />
<Bug pattern="DM_EXIT" />
</Match>
<Match>
<Class name="org.jruby.truffle.nodes.core.CoreMethodNodeManager$AmbiguousOptionalArgumentChecker" />
<Bug pattern="DM_EXIT" />
</Match>

<!-- Sometimes we really do want to run GC -->

Original file line number Diff line number Diff line change
@@ -316,7 +316,7 @@ private static void verifyNoAmbiguousOptionalArgumentsWithReflection(MethodDetai

for (int i = 1; i <= opt; i++) {
boolean unguardedObjectArgument = false;
String errors = "";
StringBuilder errors = new StringBuilder();
for (Method method : node.getDeclaredMethods()) {
if (method.isAnnotationPresent(Specialization.class)) {
// count from the end to ignore optional VirtualFrame in front.
@@ -337,7 +337,7 @@ private static void verifyNoAmbiguousOptionalArgumentsWithReflection(MethodDetai
String[] guards = method.getAnnotation(Specialization.class).guards();
if (!isGuarded(name, guards)) {
unguardedObjectArgument = true;
errors += "\"" + name + "\" in " + methodToString(method, parameterTypes, parameters) + "\n";
errors.append("\"").append(name).append("\" in ").append(methodToString(method, parameterTypes, parameters)).append("\n");
}
}
}

0 comments on commit beb71c9

Please sign in to comment.