Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tapioca does not properly attribute prepended methods #2072

Open
egiurleo opened this issue Nov 14, 2024 · 0 comments
Open

Tapioca does not properly attribute prepended methods #2072

egiurleo opened this issue Nov 14, 2024 · 0 comments
Labels
bug Something isn't working rubyconf-hackday

Comments

@egiurleo
Copy link
Contributor

I haven't verified this yet, but @paracycle told me that if one gem defines a method, and another gem overrides that method via a prepend, the prepended method will be incorrectly written to both gem RBIs.

Example:

# in gem foo
class Foo
  def foo; end
end
# in gem bar
module Bar
  def foo; end
end

Foo.prepend(Bar)

Tapioca will write bar's foo method to foo's gem RBIs, which is fine if they have the same signature, but not great if the prepend changes the method signature.

@egiurleo egiurleo added bug Something isn't working rubyconf-hackday labels Nov 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working rubyconf-hackday
Projects
None yet
Development

No branches or pull requests

1 participant