[cfe-commits] clang formatter patch to move and rename RewriterTestContext.h

Dmitri Gribenko gribozavr at gmail.com
Wed Dec 12 09:55:49 PST 2012

On Wed, Dec 12, 2012 at 7:48 PM, jahanian <fjahanian at apple.com> wrote:
> On Dec 12, 2012, at 9:42 AM, Dmitri Gribenko <gribozavr at gmail.com> wrote:
>> 2. There's a naming inconsistency: the class is called
>> 'RewriterTestContext', while the header is called
>> 'RewriterFormatContext.h'.  I think it is important to have "Test" in
>> the header name, so that it is obvious that this is not something to
>> be used outside of tests.
> The opposite, RewriterFormatContext.h will be used outside of tests. Name of
> the class inside RewriterFormatContext.h need be changed. Something that I planned
> on doing later.

Is this class good enough for use outside of tests?  It just creates
all dependencies of the Rewriter -- including, for example, a
SourceManager -- so that the Rewriter works in tests.  If you plan to
change this and, e.g., pass a SourceManager from the outside, it would
needlessly complicate tests.


(j){printf("%d\n",i);}}} /*Dmitri Gribenko <gribozavr at gmail.com>*/

More information about the cfe-commits mailing list