[cfe-dev] Clang Format not-deterministic?

Bram De Jong via cfe-dev cfe-dev at lists.llvm.org
Mon Dec 3 04:31:48 PST 2018


What I meant is that

1. running formatting first ( -i ... )
and then
2. running -output-replacements-xml afterwards, with exactly the same config

Should not give any replacements in -output-replacements-xml.
Or, am I wrong in assuming that?

Bram

On Mon, 3 Dec 2018 at 13:22, Whisperity <whisperity at gmail.com> wrote:

> There is nothing non-deterministic about this, the behaviour is
> well-documented if you say "--help":
>
>   -i                        - Inplace edit <file>s, if specified.
>
>   -output-replacements-xml  - Output replacements as XML.
>
>
> Bram De Jong via cfe-dev <cfe-dev at lists.llvm.org> ezt írta (időpont:
> 2018. dec. 3., H, 11:30):
>
>> Hi All,
>>
>> I've been noticing that clang-format either seems to be non-deterministic
>> or there is a difference between "-i" and "-output-replacements-xml".
>>
>> I.e. if you do:
>> $ clang-format -style=file -i source_code.cpp
>> $ clang-format -style=file -output-replacements-xml source_code.cpp
>>
>> The second command outputs replacements...
>>
>> Should I file a bug for this and if so, where?
>>
>> Bram
>> _______________________________________________
>> cfe-dev mailing list
>> cfe-dev at lists.llvm.org
>> http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-dev
>>
>

-- 


*Bram de Jong*
Software Management

www.holoplot.com
<http://holoplot.com/?utm_source=email&utm_medium=sg&utm_campaign=Holoplot_Signature>

+49 (0)30 407 458 12

Holoplot GmbH
Ringbahnstr. 12 (10-14) / A2
12099 Berlin, Germany
Follow us on Facebook
<https://www.facebook.com/OriginalHOLOPLOT/?utm_source=email&utm_medium=sg&utm_campaign=Holoplot_Signature>
, Twitter
<https://twitter.com/holoplot?utm_source=email&utm_medium=sg&utm_campaign=Holoplot_Signature>
 or LinkedIn
<https://www.linkedin.com/company/holoplot-gmbh?utm_source=email&utm_medium=sg&utm_campaign=Holoplot_Signature>
.
Roman Sick – CEO | HRB183974B, Register Court Charlottenburg, Germany | EU
Tax-Registration No. DE277000701 This e-mail contains confidential and/or
privileged information.
If you are not the intended recipient (or have received this e-mail in
error) please notify the sender immediately and destroy this e-mail. Any
unauthorized copying, disclosure or distribution of the information in this
e-mail is strictly forbidden.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20181203/1e4ba1a4/attachment.html>


More information about the cfe-dev mailing list