Skip to content

Commit

Permalink
core: Update signature for Module.define_method
Browse files Browse the repository at this point in the history
Inside the block for `Module.define_method` is evaluated as a instance
method.  So its self-types should be an instance of the Module.
  • Loading branch information
tk0miya committed Oct 3, 2023
1 parent a4ed27f commit 373a21f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions core/module.rbs
Original file line number Diff line number Diff line change
Expand Up @@ -726,8 +726,8 @@ class Module < Object
# I'm Dino!
# #<B:0x401b39e8>
#
def define_method: (interned symbol, Proc | Method | UnboundMethod method) -> Symbol
| (interned symbol) { () -> untyped } -> Symbol
def define_method: (interned symbol, ^() [self: instance] -> untyped | Method | UnboundMethod method) -> Symbol
| (interned symbol) { () [self: instance] -> untyped } -> Symbol

# <!--
# rdoc-file=object.c
Expand Down

0 comments on commit 373a21f

Please sign in to comment.