Use UTF-8 for all communication with clang-format
authorPhilipp Stephani <phst@google.com>
Fri, 20 Jan 2017 09:37:50 +0000 (09:37 +0000)
committerPhilipp Stephani <phst@google.com>
Fri, 20 Jan 2017 09:37:50 +0000 (09:37 +0000)
commitce2f6b413f994aebcf207a0b4fe0b06acf9ce717
tree12a0372dbfe20d898c82fe9f5bb39e7e1cdaf795
parent3cdf650770a9066fa5bb631eafe86d2a52f2f064
Use UTF-8 for all communication with clang-format

Summary: Instead of picking the buffer file coding system, always use utf-8-unix for communicating with clang-format.  This is fine because clang-format never actually reads the file to be formatted, only standard input.  This is a bit simpler (process coding system is now a constant) and potentially faster, as utf-8-unix is Emacs's internal coding system.  Also add an end-to-end test that actually invokes clang-format.

Reviewers: klimek

Reviewed By: klimek

Differential Revision: https://reviews.llvm.org/D28904

llvm-svn: 292593
clang/tools/clang-format/clang-format-test.el
clang/tools/clang-format/clang-format.el