www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.ldc - how to use clang-tidy with ldc2?

reply David <karxli77 gmail.com> writes:
Hi,

a pretty nooby question. I have ldc2 installed and realized that 
it contains clang-tiny and clang-format. However, how can I use 
clang-tiny and clang-format with ldc2 on a d-file?

Thanks, David
Dec 12 2015
parent reply kinke <noone nowhere.com> writes:
Hey there! The config files in the source tree are for the LDC 
codebase itself (since a couple of weeks). There's no such thing 
as an ldc-tidy/-format (yet).
Dec 12 2015
parent reply David <karxli77 gmail.com> writes:
On Saturday, 12 December 2015 at 22:01:40 UTC, kinke wrote:
 Hey there! The config files in the source tree are for the LDC 
 codebase itself (since a couple of weeks). There's no such 
 thing as an ldc-tidy/-format (yet).
Thanks for the quick reply. Looking forward to seeing it (maybe) one day :-)
Dec 12 2015
next sibling parent kinke <noone nowhere.com> writes:
Actually, a formatting tool would only need a D parser to get 
hold of the AST, so a LDC-specific thingy is not realistic (LDC 
translates the D AST provided by the official front-end to LLVM 
IR). You may want to have a look at dfmt 
(https://github.com/Hackerpilot/dfmt).
Dec 12 2015
prev sibling parent Russel Winder via digitalmars-d-ldc <digitalmars-d-ldc puremagic.com> writes:
On Sat, 2015-12-12 at 23:07 +0000, David via digitalmars-d-ldc wrote:
 On Saturday, 12 December 2015 at 22:01:40 UTC, kinke wrote:
 Hey there! The config files in the source tree are for the LDC=20
 codebase itself (since a couple of weeks). There's no such=20
 thing as an ldc-tidy/-format (yet).
=20 Thanks for the quick reply. Looking forward to seeing it (maybe)=20 one day :-)
Maybe you need Dfmt? https://github.com/Hackerpilot/dfmt --=20 Russel. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder ekiga.n= et 41 Buckmaster Road m: +44 7770 465 077 xmpp: russel winder.org.uk London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
Dec 13 2015