Class Pry::InputLock
In: lib/pry/input_lock.rb
Parent: Object

There is one InputLock per input (such as STDIN) as two REPLs on the same input makes things delirious. InputLock serializes accesses to the input so that threads to not conflict with each other. The latest thread to request ownership of the input wins.

Methods

Classes and Modules

Class Pry::InputLock::Interrupt

Attributes

global_lock  [RW] 
input_locks  [RW] 

Public Class methods

Public Instance methods

Adds ourselves to the ownership list. The last one in the list may access the input through interruptible_region().

[Validate]