[cfe-dev] Clang-format, odd behaviour around column limit

matthew whitehead via cfe-dev cfe-dev at lists.llvm.org
Tue Dec 15 17:53:06 PST 2015


Hi guys,
Just looking for some advice on how to fix a strange bit of behaviour that
im getting.
The problem is:
When a function call is just over the columnlimit (from 100-107
characters), the function is getting broken on the period.
when there are > 107 characters, it is packing one-per line (this is our
desired formatting).
Is there anyway to enforce that > 100 characters will always cause a
one-per line format just using a config file, or would a patch be
considered for this issue?

Attached:
clang-format,
input.txt
output.txt
cheers

Matt
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20151216/af83bb03/attachment.html>
-------------- next part --------------
aaaAaaaaa.BaaBaaaaaaaaa(aaaaaa, AaaaCaaadaIasdadaaddLasaaASDAiASDASDSADaASDSbDEASA, 1.0 + asdsDaaaaaaaa);
aaaAaaaaa.BaaBaaaaaaaaa(aaaaaa, AaaaCaaadaIasdadaaddLasaaASDAiASDASDSADaASDSbDEASA, 1.0 + asdsDaaaaaaaaa);
-------------- next part --------------
A non-text attachment was scrubbed...
Name: clang-format
Type: application/octet-stream
Size: 2108 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20151216/af83bb03/attachment.obj>
-------------- next part --------------
Traceback (most recent call last):
  File "iwyu-on-json.py", line 47, in <module>
    t.start()
  File "/usr/lib/python2.7/threading.py", line 750, in start
    self.__started.wait()
  File "/usr/lib/python2.7/threading.py", line 621, in wait
    self.__cond.wait(timeout)
  File "/usr/lib/python2.7/threading.py", line 340, in wait
    waiter.acquire()
KeyboardInterrupt
Exception KeyboardInterrupt in <module 'threading' from '/usr/lib/python2.7/threading.pyc'> ignored


More information about the cfe-dev mailing list