Completion code in "for in" statement

Completed

Hello (Sorry for my English)

I have same class in python 2.7:

class aclass:

   member1 = 0

End I am writing code:

list = []

x = aclass()

list.append(x)

for i in list:

   i.<I expect to see member1 in list members, but I do not see it>

Code working without problem.

Can it work?

 

1 comment
Comment actions Permalink

Python code can have any type added to a list. For example, you might do list.append(33) before your loop. Python and PyCharm can't do code completion in there because arrays don't have fixed-type members.

0

Please sign in to leave a comment.