Sha256: 7e626809e8af2c850a2b59f63e4ab6ec470d1e93636f2ff660e21eb9f1dcbe44

Contents?: true

Size: 536 Bytes

Versions: 4

Compression:

Stored size: 536 Bytes

Contents

def foo(k:)
end

h = { k: 42 }
foo(**h)

def bar(int:, str:)
end

if rand < 0.5
  h = { int: 42 }
else
  h = { str: "str" }
end
bar(**h)

def baz(**kw)
end

if rand < 0.5
  h = { int: 42 }
else
  h = { str: "str" }
end
baz(**h)

def qux(**kw)
end

qux(**any)

__END__
# Errors
smoke/kwsplat1.rb:30: [error] undefined method: Object#any

# Classes
class Object
  def foo : (k: Integer) -> nil
  def bar : (int: Integer, str: String) -> nil
  def baz : (**{int: Integer, str: String}) -> nil
  def qux : (**{untyped=>untyped}) -> nil
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
typeprof-0.5.3 smoke/kwsplat1.rb
typeprof-0.5.2 smoke/kwsplat1.rb
typeprof-0.5.1 smoke/kwsplat1.rb
typeprof-0.5.0 smoke/kwsplat1.rb