Skip to content

Commit 146348d

Browse files
committed
Refactoring: ProcNodes.ProcNewNode - remove not needed specialisation
1 parent 0142137 commit 146348d

File tree

1 file changed

+0
-14
lines changed

1 file changed

+0
-14
lines changed

src/main/java/org/truffleruby/core/proc/ProcNodes.java

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@
4646
import com.oracle.truffle.api.dsl.Specialization;
4747
import com.oracle.truffle.api.frame.MaterializedFrame;
4848
import com.oracle.truffle.api.frame.VirtualFrame;
49-
import com.oracle.truffle.api.object.Shape;
5049
import com.oracle.truffle.api.profiles.ConditionProfile;
5150
import com.oracle.truffle.api.source.SourceSection;
5251

@@ -75,11 +74,6 @@ protected RubyProc proc(VirtualFrame frame, RubyClass procClass, Object[] args,
7574
throw new RaiseException(getContext(), coreExceptions().argumentErrorProcWithoutBlock(this));
7675
}
7776

78-
@Specialization(guards = { "procClass == getProcClass()", "block.getShape() == getProcShape()" })
79-
protected RubyProc procNormalOptimized(RubyClass procClass, Object[] args, RubyProc block) {
80-
return block;
81-
}
82-
8377
@Specialization(guards = "procClass == metaClass(block)")
8478
protected RubyProc procNormal(RubyClass procClass, Object[] args, RubyProc block) {
8579
return block;
@@ -109,14 +103,6 @@ protected RubyProc procSpecial(VirtualFrame frame, RubyClass procClass, Object[]
109103
return proc;
110104
}
111105

112-
protected RubyClass getProcClass() {
113-
return coreLibrary().procClass;
114-
}
115-
116-
protected Shape getProcShape() {
117-
return getLanguage().procShape;
118-
}
119-
120106
protected RubyClass metaClass(RubyProc object) {
121107
return object.getMetaClass();
122108
}

0 commit comments

Comments
 (0)