llvm-project/clang/test/Rewriter
Argyrios Kyrtzidis 75627ad8ba Fix the rewriter that broke with r149987.
r149987 changed the way parsing happens inside an @implementation;
it aggregates the declarations inside and reports them together as a DeclGroup.
This had the side effect that function declarations were reported together with
their definition, while the rewriter expected for function declarations to be
reported immediately to the consumer and thus not have a body.

Fix this by having the rewriter actually check with isThisDeclarationADefinition()
to make sure the body comes from the current decl before rewriting it.

llvm-svn: 150325
2012-02-12 04:48:45 +00:00
..
blockcast3.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
blockstruct.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
crash.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
dllimport-typedef.c Change the wording of the bad-decl-for-attribute warning and error 2011-01-25 03:51:08 +00:00
finally.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
func-in-impl.m Fix the rewriter that broke with r149987. 2012-02-12 04:48:45 +00:00
id-test-3.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
inner-block-helper-funcs.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
instancetype-test.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
ivar-encoding-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
ivar-encoding-2.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
metadata-test-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
metadata-test-2.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
method-encoding-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
missing-dllimport.c fix PR7280 by making the warning on code like this: 2010-07-11 23:34:02 +00:00
objc-encoding-bug-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
objc-ivar-receiver-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
objc-string-concat-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
objc-super-test.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
objc-synchronized-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
properties.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
property-dot-syntax.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
protocol-rewrite-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
protocol-rewrite-2.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-anonymous-union.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-api-bug.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-block-argument.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-block-consts.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-block-ivar-call.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-block-literal-1.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-block-literal.c Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'. 2009-12-15 20:14:24 +00:00
rewrite-block-pointer.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-block-property.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-byref-in-nested-blocks.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-byref-vars.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-captured-nested-bvar.c Block rewriting bug. Don't take address of captured 2011-02-16 22:37:10 +00:00
rewrite-cast-ivar-access.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-cast-to-bool.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-category-property.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-constructor-init.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-eh.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-elaborated-type.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-extern-c.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-foreach-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-foreach-2.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-foreach-3.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-foreach-4.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-foreach-5.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-foreach-6.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-foreach-7.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-foreach-in-block.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-foreach-protocol-id.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-forward-class.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-forward-class.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-function-decl.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-implementation.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-ivar-use.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-local-externs-in-block.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-local-static-id.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-message-expr.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-nest.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-nested-blocks-1.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-nested-blocks-2.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-nested-blocks.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-nested-ivar.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-nested-property-in-blocks.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-no-nextline.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-property-attributes.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-property-set-cfstring.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-protocol-property.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-protocol-qualified.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-protocol-type-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-qualified-id.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-rewritten-initializer.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-static-block.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-super-message.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-trivial-constructor.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-try-catch.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-typeof.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-unique-block-api.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-user-defined-accessors.mm Also, these objc++ rewriter tests are meant to run in NeXt's 2012-02-04 19:06:06 +00:00
rewrite-vararg.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
rewrite-weak-attr.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
static-type-protocol-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
undecl-objc-h.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
undeclared-method-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
undef-field-reference-1.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
va-method.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00
weak_byref_objects.m These tests are intended to run in NeXt's legacy objective-c abi (fragile-abi). 2012-02-04 18:56:43 +00:00