We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
Object#sleep
Object#sleep_ms
1 parent 72aa743 commit ec4c4abCopy full SHA for ec4c4ab
2 files changed
core/object.rbs
@@ -84,4 +84,8 @@ class Object < BasicObject
84
alias self.inspect self.to_s
85
86
def loop: () { () -> void } -> bot
87
+
88
+ def sleep: (Integer | Float sec) -> Integer
89
90
+ def sleep_ms: (Integer ms) -> Integer
91
end
test/object.rb
@@ -128,4 +128,9 @@ module TestMod end
128
129
loop { puts }
130
131
+sleep 1
132
+sleep 1.0
133
134
+sleep_ms 1000
135
136
# rubocop:enable all
0 commit comments