@@ -114,6 +114,7 @@ public static IRubyObject initiateNonLocalReturn(ThreadContext context, DynamicS
114114 throw IRReturnJump .create (dynScope , returnValue );
115115 }
116116
117+ @ JIT
117118 public static IRubyObject handleNonlocalReturn (StaticScope scope , DynamicScope dynScope , Object rjExc , Block .Type blockType ) throws RuntimeException {
118119 if (!(rjExc instanceof IRReturnJump )) {
119120 Helpers .throwException ((Throwable )rjExc );
@@ -157,6 +158,7 @@ public static IRubyObject initiateBreak(ThreadContext context, DynamicScope dynS
157158 }
158159 }
159160
161+ @ JIT
160162 public static IRubyObject handleBreakAndReturnsInLambdas (ThreadContext context , StaticScope scope , DynamicScope dynScope , Object exc , Block .Type blockType ) throws RuntimeException {
161163 if ((exc instanceof IRBreakJump ) && inNonMethodBodyLambda (scope , blockType )) {
162164 // We just unwound all the way up because of a non-local break
@@ -173,6 +175,7 @@ public static IRubyObject handleBreakAndReturnsInLambdas(ThreadContext context,
173175 }
174176 }
175177
178+ @ JIT
176179 public static IRubyObject handlePropagatedBreak (ThreadContext context , DynamicScope dynScope , Object bjExc , Block .Type blockType ) {
177180 if (!(bjExc instanceof IRBreakJump )) {
178181 Helpers .throwException ((Throwable )bjExc );
@@ -531,17 +534,20 @@ public static IRubyObject extractOptionalArgument(RubyArray rubyArray, int minAr
531534 return minArgsLength < n ? rubyArray .entry (index ) : UndefinedValue .UNDEFINED ;
532535 }
533536
537+ @ JIT
534538 public static IRubyObject isDefinedBackref (ThreadContext context ) {
535539 return RubyMatchData .class .isInstance (context .getBackRef ()) ?
536540 context .runtime .getDefinedMessage (DefinedMessage .GLOBAL_VARIABLE ) : context .nil ;
537541 }
538542
543+ @ JIT
539544 public static IRubyObject isDefinedGlobal (ThreadContext context , String name ) {
540545 return context .runtime .getGlobalVariables ().isDefined (name ) ?
541546 context .runtime .getDefinedMessage (DefinedMessage .GLOBAL_VARIABLE ) : context .nil ;
542547 }
543548
544549 // FIXME: This checks for match data differently than isDefinedBackref. Seems like they should use same mechanism?
550+ @ JIT
545551 public static IRubyObject isDefinedNthRef (ThreadContext context , int matchNumber ) {
546552 IRubyObject backref = context .getBackRef ();
547553
@@ -554,6 +560,7 @@ public static IRubyObject isDefinedNthRef(ThreadContext context, int matchNumber
554560 return context .nil ;
555561 }
556562
563+ @ JIT
557564 public static IRubyObject isDefinedClassVar (ThreadContext context , RubyModule receiver , String name ) {
558565 boolean defined = receiver .isClassVarDefined (name );
559566
@@ -566,23 +573,27 @@ public static IRubyObject isDefinedClassVar(ThreadContext context, RubyModule re
566573 return defined ? context .runtime .getDefinedMessage (DefinedMessage .CLASS_VARIABLE ) : context .nil ;
567574 }
568575
576+ @ JIT
569577 public static IRubyObject isDefinedInstanceVar (ThreadContext context , IRubyObject receiver , String name ) {
570578 return receiver .getInstanceVariables ().hasInstanceVariable (name ) ?
571579 context .runtime .getDefinedMessage (DefinedMessage .INSTANCE_VARIABLE ) : context .nil ;
572580 }
573581
582+ @ JIT
574583 public static IRubyObject isDefinedCall (ThreadContext context , IRubyObject self , IRubyObject receiver , String name ) {
575584 RubyString boundValue = Helpers .getDefinedCall (context , self , receiver , name );
576585
577586 return boundValue == null ? context .nil : boundValue ;
578587 }
579588
589+ @ JIT
580590 public static IRubyObject isDefinedConstantOrMethod (ThreadContext context , IRubyObject receiver , String name ) {
581591 RubyString definedType = Helpers .getDefinedConstantOrBoundMethod (receiver , name );
582592
583593 return definedType == null ? context .nil : definedType ;
584594 }
585595
596+ @ JIT
586597 public static IRubyObject isDefinedMethod (ThreadContext context , IRubyObject receiver , String name , boolean checkIfPublic ) {
587598 DynamicMethod method = receiver .getMetaClass ().searchMethod (name );
588599
@@ -594,6 +605,7 @@ public static IRubyObject isDefinedMethod(ThreadContext context, IRubyObject rec
594605 return context .nil ;
595606 }
596607
608+ @ JIT
597609 public static IRubyObject isDefinedSuper (ThreadContext context , IRubyObject receiver ) {
598610 boolean flag = false ;
599611 String frameName = context .getFrameName ();
@@ -657,6 +669,7 @@ public static RubyModule getModuleFromScope(ThreadContext context, StaticScope s
657669 return rubyClass ;
658670 }
659671
672+ @ JIT
660673 public static IRubyObject mergeKeywordArguments (ThreadContext context , IRubyObject restKwarg , IRubyObject explcitKwarg ) {
661674 return ((RubyHash ) TypeConverter .checkHashType (context .runtime , restKwarg )).merge (context , explcitKwarg , Block .NULL_BLOCK );
662675 }
0 commit comments