Skip to content

Fix #826 #868

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

Merged
merged 1 commit into from
Mar 27, 2018
Merged

Fix #826 #868

merged 1 commit into from
Mar 27, 2018

Conversation

jennaliu
Copy link

previous_definition could reach the first line during the loop. Simply checking it before entering the loop is not enough.

@diraol
Copy link
Contributor

diraol commented Mar 27, 2018

Hi @jennaliu thanks for your contribution!

Can you provide any kind of example in which the previous version fails but it works with the newer code?
Even better if you can add it to our test suite! =)

@jennaliu
Copy link
Author

When opening a file with class or function definitions at the beginning of the file, Vim freezes. To test it, create a file with the following content (no empty lines at the beginning of the file), and open it with Vim. Sorry, I am not very familiar with the test suite right now. I submitted this pull request because it fixed my issue and I thought it could also help others.

class Class1:

    def __init__(self):
        super().__init__()


class Class2:

    def __init__(self):
        super().__init__()

@diraol
Copy link
Contributor

diraol commented Mar 27, 2018

Don't worry @jennaliu !!
Thanks for your contribution!

@diraol diraol merged commit 126b09b into python-mode:develop Mar 27, 2018
@fmv1992
Copy link
Contributor

fmv1992 commented Mar 28, 2018

Thank you and thanks @diraol for your steady collaboration!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants