Interpreter knowledge needed to interpret a closure.
<init>(org.jruby.ir.IRClosure scope, java.util.function.Supplier<List<org.jruby.ir.instructions.Instr>> instructions, int temporaryVariableCount, EnumSet<org.jruby.ir.IRFlags> flags)newDynamicScope(org.jruby.runtime.ThreadContext context)Blocks have more complicated logic for pushing a dynamic scope (see InterpretedIRBlockBody). We throw an error in case somehow we mistakenly try and push a binding.
| field | type | note |
|---|---|---|
| instructionsCallback | Supplier<List<Instr>> |
allocateTemporaryBooleanVariables()allocateTemporaryFixnumVariables()allocateTemporaryFloatVariables()allocateTemporaryVariables()computeScopeFlagsFromInstructions()setDynamicScopeEliminated(boolean dynamicScopeEliminated) · also: set_dynamic_scope_eliminatedisDynamicScopeEliminated() · also: is_dynamic_scope_eliminatedisEND() · also: is_endsetExplicitCallProtocol(boolean callProtocol) · also: set_explicit_call_protocolgetFileName() · also: get_file_namehasExplicitCallProtocol() · also: has_explicit_call_protocolgetLine() · also: get_linepopDynScope()pushNewDynScope()receivesKeywordArguments()getRequiredArgsCount() · also: get_required_args_countgetRescueIPCs() · also: get_rescue_ip_csreuseParentDynScope()setReuseParentDynScope(boolean reuseParentDynScope) · also: set_reuse_parent_dyn_scopeisRuby2Keywords() · also: is_ruby2_keywordsgetTemporaryVariableCount() · also: get_temporary_variable_counttoString()toStringInstrs()