Closed GoogleCodeExporter closed 9 years ago
I think this already exists, if you do the following code for example:
val = ''
val = foo()
val.<CODE COMPLETE WORKS HERE>
... then the code complete knows val is a string.
Perhaps I'm misunderstanding your issue?
Original comment by Chris.W....@gmail.com
on 5 Jul 2012 at 10:41
OK, I'm learning... I was unable to get code completion for a number of types,
such as string. I'm not sure exactly why that was happening, but it seems to
be working now.
SOME CLARIFICATIONS:
There are still two primary situations where PyScripter's code completion
breaks down:
1. function parameters
2. accessing attributes of a returned value
In the first case, assignig something to a parameter wipes it out, so is not an
option.
def delfind( str, sub):
str = '' #oops, bad idea
pos = str.find( sub)
#^ no code completion help
if pos >= 0:
return str[:pos]+str[pos+len(sub):]
else
return str
a= delfind('hi bye').strip()
# ^no help here either
Don't know the best solution, but there's gotta be SOMETHING.
Original comment by AgentFri...@gmail.com
on 7 Jul 2012 at 12:25
Please read
https://groups.google.com/forum/?fromgroups#!searchin/pyscripter/Code$20completi
on/pyscripter/TadjX_PO4fo/EXAcsqHZNS0J for explanation of code completion in
PyScripter.
Also http://pyscripter.blogspot.gr/2010/10/code-completion-delight.html and
other blog posts about code completion.
Original comment by pyscripter
on 11 Jul 2012 at 5:12
Original comment by pyscripter
on 11 Jul 2012 at 5:13
[deleted comment]
HERE IS A WORKAROUND for function parameters, which I've found quite helpful...
def myfunc( param1, param2):
if 0:
param1 = ''
param2 = SomeClass()
param2. ...
Now if only it could be done w/ out adding dead code.
Original comment by AgentFri...@gmail.com
on 13 Jul 2012 at 8:52
Original issue reported on code.google.com by
AgentFri...@gmail.com
on 5 Jul 2012 at 5:54