summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/lldbbench.py
Commit message (Collapse)AuthorAgeFilesLines
* *** This commit represents a complete reformatting of the LLDB source codeKate Stone2016-09-061-11/+11
| | | | | | | | | | | | | | | | | | | | | | | *** to conform to clang-format’s LLVM style. This kind of mass change has *** two obvious implications: Firstly, merging this particular commit into a downstream fork may be a huge effort. Alternatively, it may be worth merging all changes up to this commit, performing the same reformatting operation locally, and then discarding the merge for this particular commit. The commands used to accomplish this reformatting were as follows (with current working directory as the root of the repository): find . \( -iname "*.c" -or -iname "*.cpp" -or -iname "*.h" -or -iname "*.mm" \) -exec clang-format -i {} + find . -iname "*.py" -exec autopep8 --in-place --aggressive --aggressive {} + ; The version of clang-format used was 3.9.0, and autopep8 was 1.2.4. Secondly, “blame” style tools will generally point to this commit instead of a meaningful prior commit. There are alternatives available that will attempt to look through this change and find the appropriate prior commit. YMMV. llvm-svn: 280751
* Python 3 - Turn on absolute imports, and fix existing imports.Zachary Turner2015-11-051-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Absolute imports were introduced in Python 2.5 as a feature (e.g. from __future__ import absolute_import), and made default in Python 3. When absolute imports are enabled, the import system changes in a couple of ways: 1) The `import foo` syntax will *only* search sys.path. If `foo` isn't in sys.path, it won't be found. Period. Without absolute imports, the import system will also search the same directory that the importing file resides in, so that you can easily import from the same folder. 2) From inside a package, you can use a dot syntax to refer to higher levels of the current package. For example, if you are in the package lldbsuite.test.utility, then ..foo refers to lldbsuite.test.foo. You can use this notation with the `from X import Y` syntax to write intra-package references. For example, using the previous locationa s a starting point, writing `from ..support import seven` would import lldbsuite.support.seven Since this is now the default behavior in Python 3, this means that importing from the same directory with `import foo` *no longer works*. As a result, the only way to have portable code is to force absolute imports for all versions of Python. See PEP 0328 [https://www.python.org/dev/peps/pep-0328/] for more information about absolute and relative imports. Differential Revision: http://reviews.llvm.org/D14342 Reviewed By: Todd Fiala llvm-svn: 252191
* Move lldb/test to lldb/packages/Python/lldbsuite/test.Zachary Turner2015-10-281-0/+112
This is the conclusion of an effort to get LLDB's Python code structured into a bona-fide Python package. This has a number of benefits, but most notably the ability to more easily share Python code between different but related pieces of LLDB's Python infrastructure (for example, `scripts` can now share code with `test`). llvm-svn: 251532
OpenPOWER on IntegriCloud