summaryrefslogtreecommitdiffstats
path: root/lldb/scripts/Python
diff options
context:
space:
mode:
authorJoel E. Denny <jdenny.ornl@gmail.com>2019-10-16 17:21:24 +0000
committerJoel E. Denny <jdenny.ornl@gmail.com>2019-10-16 17:21:24 +0000
commitf095b8c425ecf832d0a5ccdbaa02c27153f80a0c (patch)
tree69651c319a801cdab8ea500840dfb744ebdfa48b /lldb/scripts/Python
parentf89cf21337b07e0f6fc3704eadaddc05aa845831 (diff)
downloadbcm5719-llvm-f095b8c425ecf832d0a5ccdbaa02c27153f80a0c.tar.gz
bcm5719-llvm-f095b8c425ecf832d0a5ccdbaa02c27153f80a0c.zip
[lit] Clean up internal diff's encoding handling
As suggested by rnk at D67643#1673043, instead of reading files multiple times until an appropriate encoding is found, read them once as binary, and then try to decode what was read. For Python >= 3.5, don't fail when attempting to decode the `diff_bytes` output in order to print it. Avoid failures for Python 2.7 used on some Windows bots by transforming diff output with `lit.util.to_string` before writing it to stdout. Finally, add some tests for encoding handling. Reviewed By: rnk Differential Revision: https://reviews.llvm.org/D68664 llvm-svn: 375018
Diffstat (limited to 'lldb/scripts/Python')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud