[Differential] [Request, 49 lines] D3640: Skip explicit `self` argument when calling via class.

flherne (Francis Herne) noreply at phabricator.kde.org
Sat Dec 10 22:58:35 UTC 2016


flherne created this revision.
flherne added a reviewer: brauch.
flherne set the repository for this revision to R53 KDevelop: Python Support.
Restricted Application added a subscriber: kdevelop-devel.

REVISION SUMMARY
  Instance methods can be called via the class:
   `Class.method(instance, arg)`
  
  Self arguments are handled separately. With an explicit `instance` argument as in the example, its type was wrongly used for the next argument with all subsequent argtypes offset by one.
  
  BUG: 369364
  
  Simply skip such arguments where they exist.

TEST PLAN
  Test `method_explicit_self` previously failed, now passes.
  Test `parent_constructor_arg_type` previously failed.
  Now it fails on the first run, but gets the correct type if reloading the document.
  Probably related to https://bugs.kde.org/show_bug.cgi?id=306213
  
  Other new tests passed already.
  No test regressions.

REPOSITORY
  R53 KDevelop: Python Support

REVISION DETAIL
  https://phabricator.kde.org/D3640

AFFECTED FILES
  duchain/declarationbuilder.cpp
  duchain/tests/pyduchaintest.cpp

EMAIL PREFERENCES
  https://phabricator.kde.org/settings/panel/emailpreferences/

To: flherne, brauch
Cc: kdevelop-devel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20161210/902c92cb/attachment.html>


More information about the KDevelop-devel mailing list