method
safe_level
safe_level()
public
Returns the safe level in effect for thr. Setting thread-local safe levels can help when implementing sandboxes which run insecure code.
thr = Thread.new { $SAFE = 3; sleep } Thread.current.safe_level #=> 0 thr.safe_level #=> 3