Reputation: 48644
I'm looking for an extension which will help in Python's auto complete feature in Python.
If I type the following code:
a = [4,5,6]
a.p
Then I expect it would give me a suggestion for pop
as it is one of the method of Python list. Is this thing achievable in Emacs?
I tried installing Rope, Rope mode, Ropemacs and Pymacs. The auto-complete suggestion, I get from that aren't the methods of list. But it suggests me something like print
etc. Am I doing something wrong ?
Upvotes: 1
Views: 311
Reputation: 2786
Works for me with vimrope
from https://github.com/python-rope/ropevim/ (now, the official home of all rope projects)
Upvotes: 0
Reputation: 41990
Because Python variables don't have types, it is difficult to know what class of object a variable would contain at a given point in your code. Imagine if your code later did a = 1
. Emacs would have to know when the variable a refers to a list and when it refers to a number in order to offer the correct completion. Generally this is not possible without actually running the code.
Upvotes: 0