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

Compilation error after applying the Inline method refactoring #745

Open
jonhnanthan opened this issue Jan 15, 2024 · 0 comments
Open

Compilation error after applying the Inline method refactoring #745

jonhnanthan opened this issue Jan 15, 2024 · 0 comments
Labels
bug Unexpected or incorrect user-visible behavior inline-refactor

Comments

@jonhnanthan
Copy link

jonhnanthan commented Jan 15, 2024

Rope causes a compilation error after modifying the loop inside the return using the inlined method.
It would be nice if Rope sent a warning to the user that the method has an empty body.

Steps to reproduce the behavior:

  1. Code before refactoring:
class MyTokenizer:

    def tokenize(self, text):
        return

    def itokenize(self, text):
        return (t for t in self.tokenize(text))
  1. Apply the Inline Method to MyTokenizer.tokenize();
@jonhnanthan jonhnanthan added the bug Unexpected or incorrect user-visible behavior label Jan 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Unexpected or incorrect user-visible behavior inline-refactor
Projects
None yet
Development

No branches or pull requests

2 participants