Commit Graph

8 Commits

Author SHA1 Message Date
Eric Liu 3a7e13140a [change-namespace] trying to fix windows buildbot failure.
llvm-svn: 296458
2017-02-28 10:00:15 +00:00
Eric Liu 4c8767fa55 [change-namespace] fix asan failure in r296110.
llvm-svn: 296113
2017-02-24 12:56:51 +00:00
Eric Liu 7fccc9995a [change-namepsace] make it possible to whitelist symbols so they don't get updated.
Reviewers: hokein

Reviewed By: hokein

Subscribers: cfe-commits

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

llvm-svn: 296110
2017-02-24 11:54:45 +00:00
Eric Liu a13c419a29 [change-namespace] add an option to dump changed files in YAML.
Reviewers: hokein

Reviewed By: hokein

Subscribers: fhahn, cfe-commits

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

llvm-svn: 294969
2017-02-13 17:24:14 +00:00
Eric Liu 3db05219f7 Print stack trace for clang-change-namespace tool.
llvm-svn: 284147
2016-10-13 18:56:14 +00:00
Haojian Wu b530f1649e [change-namespace] Pass Style to ChangeNamespaceTool.
llvm-svn: 283338
2016-10-05 17:00:40 +00:00
Eric Liu 77b0c1adee Add missing dependency to change-namespace.
llvm-svn: 281935
2016-09-19 20:41:39 +00:00
Eric Liu 495b211a6c A clang tool for changing surrouding namespaces of class/function definitions.
Summary:
A tool for changing surrouding namespaces of class/function definitions while keeping
references to types in the changed namespace correctly qualified by prepending
namespace specifiers before them.

Example: test.cc
   namespace na {
   class X {};
   namespace nb {
   class Y { X x; };
   } // namespace nb
   } // namespace na

To move the definition of class Y from namespace "na::nb" to "x::y", run:
   clang-change-namespace --old_namespace "na::nb" \
     --new_namespace "x::y" --file_pattern "test.cc" test.cc --

Output:
   namespace na {
   class X {};
   } // namespace na
   namespace x {
   namespace y {
   class Y { na::X x; };
   } // namespace y
   } // namespace x

Reviewers: alexfh, omtcyfz, hokein

Subscribers: mgorny, klimek, djasper, beanz, alexshap, Eugene.Zelenko, cfe-commits

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

llvm-svn: 281918
2016-09-19 17:40:32 +00:00