diff --git a/lib/pry/pry_instance.rb b/lib/pry/pry_instance.rb index 700fff27..9e8848e9 100644 --- a/lib/pry/pry_instance.rb +++ b/lib/pry/pry_instance.rb @@ -79,6 +79,12 @@ class Pry true end + # The currently active `Binding`. + # @return [Binding] The currently active `Binding` for the session. + def current_context + binding_stack.last + end + # The current prompt. # This is the prompt at the top of the prompt stack. #