[kdev-python] [Bug 309817] Wrong scope in the list of superclasses

2016-11-30 Thread Francis Herne
https://bugs.kde.org/show_bug.cgi?id=309817

Francis Herne  changed:

   What|Removed |Added

 Resolution|--- |FIXED
  Latest Commit|http://commits.kde.org/kdev |https://commits.kde.org/kde
   |-python/d74d1f413669c45e461 |v-python/d324e78c60cda606c6
   |0a5da4591002b424f6e7f   |61f01b4b49defd93829c00
 Status|REOPENED|RESOLVED

--- Comment #7 from Francis Herne  ---
Git commit d324e78c60cda606c661f01b4b49defd93829c00 by Francis Herne.
Committed on 30/11/2016 at 14:51.
Pushed by flherne into branch 'master'.

Shorten class context range by one line.

Class contexts behave in some ways (tooltips, completion) as if they're
 one line longer than they ought to be:
```
a = 2
class M:
  a = "text"
b = a # tooltip of `a` says 'str', should be 'int'
a # 'int'
```
Expression-visitor doesn't have that problem, i.e. `b` is 'int' in the
 example above.

Shortening the class context range by one line fixes tooltips, uses and
 completions, and doesn't seem to break the expression visitor.

Test case "class_scope_end_outside" is fixed by this patch, the others
 are unchanged.

M  +17   -0codecompletion/tests/pycompletiontest.cpp
M  +2-0codecompletion/tests/pycompletiontest.h
M  +1-1duchain/contextbuilder.cpp
M  +5-0duchain/tests/pyduchaintest.cpp

https://commits.kde.org/kdev-python/d324e78c60cda606c661f01b4b49defd93829c00

-- 
You are receiving this mail because:
You are watching all bug changes.

[kdev-python] [Bug 309817] Wrong scope in the list of superclasses

2016-11-30 Thread Francis Herne
https://bugs.kde.org/show_bug.cgi?id=309817

Francis Herne  changed:

   What|Removed |Added

 CC||m...@flherne.uk

--- Comment #6 from Francis Herne  ---
The remaining case seems much simpler - class contexts are simply one line too
long.
```
foo = "jkj"
class Test:
 foo=42
bar  # int, should be str
bar  # str
```

-- 
You are receiving this mail because:
You are watching all bug changes.

[kdev-python] [Bug 309817] Wrong scope in the list of superclasses

2016-09-25 Thread Nicolás Alvarez via KDE Bugzilla
https://bugs.kde.org/show_bug.cgi?id=309817

--- Comment #5 from Nicolás Alvarez  ---
(In reply to Sven Brauch from comment #4)
> Note: This corner-case is still broken (discivered by Nicolas):
> [...]
> To be fixed for 1.5.

I confirm this is still broken in 5.0.1...

-- 
You are receiving this mail because:
You are watching all bug changes.