aboutsummaryrefslogtreecommitdiffstats
path: root/share/qtcreator
diff options
context:
space:
mode:
authorJeremy Ephron <jeremyephron@gmail.com>2020-09-09 18:31:50 -0700
committerJeremy Barenholtz <jeremyephron@gmail.com>2020-09-10 17:53:25 +0000
commit495c08a3eb018e9c2bb6bec4a8d128861b299973 (patch)
tree2c8590b669ea62a75feef97bec36473456df2b20 /share/qtcreator
parentb9445d5627bcd3d306346d7b7d418362f8f7f509 (diff)
Debugger: Don't hardcode dumper module names
Changed the dumpermodules list to be dynamically retrieved as all <module_name>types.py files instead of a hardcoded list. I don't know of any reason it should be a hardcoded list, and this allows for more than one custom extra dumper file instead of having to specify one extra one and/or use personaltypes.py. It seems strictly better. The code used is confirmed to be compatible with all versions of Python. Change-Id: Ic1988961d5cb7e6523e84afdd0e6c4ed2993ac97 Reviewed-by: Christian Stenger <christian.stenger@qt.io> Reviewed-by: hjk <hjk@qt.io>
Diffstat (limited to 'share/qtcreator')
-rw-r--r--share/qtcreator/debugger/dumper.py10
1 files changed, 3 insertions, 7 deletions
diff --git a/share/qtcreator/debugger/dumper.py b/share/qtcreator/debugger/dumper.py
index 3cca1f1f56..13a0986268 100644
--- a/share/qtcreator/debugger/dumper.py
+++ b/share/qtcreator/debugger/dumper.py
@@ -26,6 +26,7 @@
import os
import codecs
import collections
+import glob
import struct
import sys
import base64
@@ -207,13 +208,8 @@ class DumperBase():
self.childrenSuffix = '],'
self.dumpermodules = [
- 'qttypes',
- 'stdtypes',
- 'misctypes',
- 'boosttypes',
- 'opencvtypes',
- 'creatortypes',
- 'personaltypes',
+ os.path.splitext(os.path.basename(p))[0] for p in
+ glob.glob(os.path.join(os.path.dirname(__file__), '*types.py'))
]
# These values are never used, but the variables need to have