rbs icon indicating copy to clipboard operation
rbs copied to clipboard

Signature for MemoryView

Open KitaitiMakoto opened this issue 1 year ago • 0 comments

Hello,

When a method accepts arguments that expose MemoryView, we cannot represent that in current RBS (v3.8.1) and type check by Steep fails. We need a way to represent an object which exposes MemoryView.

As just an idea, a special phantom module RBS::Marker::MemoryView might play a role in this case:

class AMemoryViewProducer
  include RBS::Marker::MemoryView
end

class AMemoryViewConsumer
  def consume_memory_view: (RBS::Marker::MemoryView) -> void
end

I think we need more discussion. How do you think?

Thanks.

KitaitiMakoto avatar Dec 30 '24 17:12 KitaitiMakoto