Preview Ruby 4.1 is a preview. It can change before the final release. Switch to Ruby 4.0 →
instance method
IO::Buffer#empty?
() -> bool
empty? → true or false
io_buffer.c
View on GitHub ↗
static VALUE
rb_io_buffer_empty_p(VALUE self)
{
struct rb_io_buffer_view *buffer = get_io_buffer_view(self);
return RBOOL(buffer->size == 0);
}