Skip to content

Commit 5cdbe74

Browse files
committedFeb 5, 2018
Alias must pass its name, not given name.
1 parent 6c1fd1f commit 5cdbe74

File tree

1 file changed

+20
-20
lines changed

1 file changed

+20
-20
lines changed
 

Diff for: ‎core/src/main/java/org/jruby/internal/runtime/methods/AliasMethod.java

+20-20
Original file line numberDiff line numberDiff line change
@@ -52,53 +52,53 @@ public AliasMethod(RubyModule implementationClass, DynamicMethod oldMethod, Stri
5252
}
5353

5454
@Override
55-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name) {
56-
return oldMethod.call(context, self, klazz, oldName);
55+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused) {
56+
return oldMethod.call(context, self, klazz, name);
5757
}
5858

5959
@Override
60-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg) {
61-
return oldMethod.call(context, self, klazz, oldName, arg);
60+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg) {
61+
return oldMethod.call(context, self, klazz, name, arg);
6262
}
6363

6464
@Override
65-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg1, IRubyObject arg2) {
66-
return oldMethod.call(context, self, klazz, oldName, arg1, arg2);
65+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, IRubyObject arg2) {
66+
return oldMethod.call(context, self, klazz, name, arg1, arg2);
6767
}
6868

6969
@Override
70-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg1, IRubyObject arg2, IRubyObject arg3) {
71-
return oldMethod.call(context, self, klazz, oldName, arg1, arg2, arg3);
70+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, IRubyObject arg2, IRubyObject arg3) {
71+
return oldMethod.call(context, self, klazz, name, arg1, arg2, arg3);
7272
}
7373

7474
@Override
75-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject[] args) {
76-
return oldMethod.call(context, self, klazz, oldName, args);
75+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject[] args) {
76+
return oldMethod.call(context, self, klazz, name, args);
7777
}
7878

7979
@Override
80-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, Block block) {
81-
return oldMethod.call(context, self, klazz, oldName, block);
80+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused, Block block) {
81+
return oldMethod.call(context, self, klazz, name, block);
8282
}
8383

8484
@Override
85-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg1, Block block) {
86-
return oldMethod.call(context, self, klazz, oldName, arg1, block);
85+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, Block block) {
86+
return oldMethod.call(context, self, klazz, name, arg1, block);
8787
}
8888

8989
@Override
90-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg1, IRubyObject arg2, Block block) {
91-
return oldMethod.call(context, self, klazz, oldName, arg1, arg2, block);
90+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, IRubyObject arg2, Block block) {
91+
return oldMethod.call(context, self, klazz, name, arg1, arg2, block);
9292
}
9393

9494
@Override
95-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject arg1, IRubyObject arg2, IRubyObject arg3, Block block) {
96-
return oldMethod.call(context, self, klazz, oldName, arg1, arg2, arg3, block);
95+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject arg1, IRubyObject arg2, IRubyObject arg3, Block block) {
96+
return oldMethod.call(context, self, klazz, name, arg1, arg2, arg3, block);
9797
}
9898

9999
@Override
100-
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String name, IRubyObject[] args, Block block) {
101-
return oldMethod.call(context, self, klazz, oldName, args, block);
100+
public IRubyObject call(ThreadContext context, IRubyObject self, RubyModule klazz, String unused, IRubyObject[] args, Block block) {
101+
return oldMethod.call(context, self, klazz, name, args, block);
102102
}
103103

104104
public DynamicMethod dup() {

0 commit comments

Comments
 (0)