[Lldb-commits] [PATCH] D121786: [LLDB] Update inspect getargspec to getfullargspec

Muhammad Omair Javaid via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Wed Mar 16 03:16:00 PDT 2022


omjavaid created this revision.
omjavaid added a reviewer: labath.
omjavaid added a project: LLDB.
Herald added subscribers: JDevlieghere, kristof.beyls.
Herald added a project: All.
omjavaid requested review of this revision.

This patch replaces getargspec with getfullargspec in funcutils.py.
getargspec has been deprecated by python 11x release. This is 
important to run LLDB testsuite in Windows/Arm64 platform 
where Python native will be available from python release onwards.

Note: getfullargspec is not available in python 2


https://reviews.llvm.org/D121786

Files:
  lldb/packages/Python/lldbsuite/support/funcutils.py


Index: lldb/packages/Python/lldbsuite/support/funcutils.py
===================================================================
--- lldb/packages/Python/lldbsuite/support/funcutils.py
+++ lldb/packages/Python/lldbsuite/support/funcutils.py
@@ -1,7 +1,7 @@
 import inspect
 
 def requires_self(func):
-    func_argc = len(inspect.getargspec(func).args)
+    func_argc = len(inspect.getfullargspec(func).args)
     if func_argc == 0 or (
         getattr(
             func,


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D121786.415758.patch
Type: text/x-patch
Size: 472 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/lldb-commits/attachments/20220316/289b2707/attachment.bin>


More information about the lldb-commits mailing list