Skip to content

Commit

Permalink
Showing 3 changed files with 10 additions and 0 deletions.
3 changes: 3 additions & 0 deletions core/src/main/java/org/jruby/RubyModule.java
Original file line number Diff line number Diff line change
@@ -976,13 +976,16 @@ public static final class MethodClumper {
public Map<Set<FrameField>, List<String>> readGroups = Collections.EMPTY_MAP;
public Map<Set<FrameField>, List<String>> writeGroups = Collections.EMPTY_MAP;

@SuppressWarnings("deprecation")
public void clump(final Class cls) {
Method[] declaredMethods = Initializer.DECLARED_METHODS.get(cls);
for (Method method: declaredMethods) {
JRubyMethod anno = method.getAnnotation(JRubyMethod.class);

if (anno == null) continue;

if (anno.compat() == org.jruby.CompatVersion.RUBY1_8) continue;

// skip bridge methods, as generated by JDK8 javac for e.g. return-value overloaded methods
if (method.isBridge()) continue;

4 changes: 4 additions & 0 deletions core/src/main/java/org/jruby/anno/AnnotationBinder.java
Original file line number Diff line number Diff line change
@@ -94,6 +94,7 @@ public SourceVersion getSupportedSourceVersion() {
return SourceVersion.latest();
}

@SuppressWarnings("deprecation")
public void processType(TypeElement cd) {
// process inner classes
for (TypeElement innerType : ElementFilter.typesIn(cd.getEnclosedElements())) {
@@ -164,8 +165,11 @@ public void processType(TypeElement cd) {
int methodCount = 0;
for (ExecutableElement method : ElementFilter.methodsIn(cd.getEnclosedElements())) {
JRubyMethod anno = method.getAnnotation(JRubyMethod.class);

if (anno == null) continue;

if (anno.compat() == org.jruby.CompatVersion.RUBY1_8) continue;

methodCount++;

checkForThrows(cd, method);
3 changes: 3 additions & 0 deletions core/src/main/java/org/jruby/anno/IndyBinder.java
Original file line number Diff line number Diff line change
@@ -110,6 +110,7 @@ public SourceVersion getSupportedSourceVersion() {
return SourceVersion.latest();
}

@SuppressWarnings("deprecation")
public void processType(TypeElement cd) {
// process inner classes
for (TypeElement innerType : ElementFilter.typesIn(cd.getEnclosedElements())) {
@@ -188,6 +189,8 @@ public void processType(TypeElement cd) {
JRubyMethod anno = method.getAnnotation(JRubyMethod.class);
if (anno == null) continue;

if (anno.compat() == org.jruby.CompatVersion.RUBY1_8) continue;

methodCount++;

AnnotationBinder.checkForThrows(cd, method);

0 comments on commit 065cf78

Please sign in to comment.