summaryrefslogtreecommitdiffstats
path: root/clang/test/ASTMerge
Commit message (Collapse)AuthorAgeFilesLines
* [ASTImporter] Implement missing VisitAccessSpecDecl function in ASTImporter ↵Argyrios Kyrtzidis2016-02-183-8/+10
| | | | | | | | class. Patch by Elisavet Sakellari! llvm-svn: 261274
* Update tests touched by r249656David Majnemer2015-10-082-6/+6
| | | | | | | | | These test updates almost exclusively around the change in behavior around enum: enums without a definition are considered incomplete except when targeting MSVC ABIs. Since these tests are interested in the 'incomplete-enum' behavior, restrict them to %itanium_abi_triple. llvm-svn: 249660
* PR10405 - Desugar FunctionType and TemplateSpecializationType if any type ↵Nikola Smiljanic2015-07-161-1/+1
| | | | | | that appears inside needs to be desugared. llvm-svn: 242371
* [Hexagon] Reapply 238773 after fix to LLVM.Colin LeMahieu2015-06-031-1/+0
| | | | llvm-svn: 238948
* Revert "[Hexagon] Test passes for hexagon target now that the backend ↵Rafael Espindola2015-06-011-0/+1
| | | | | | | | | | correctly generates relocations." This reverts commit r238754. It depends on r238748, which was reverted. llvm-svn: 238773
* [Hexagon] Test passes for hexagon target now that the backend correctly ↵Colin LeMahieu2015-06-011-1/+0
| | | | | | generates relocations. llvm-svn: 238754
* XFAIL Hexagon until more codegen in place.Rick Foos2015-04-291-0/+1
| | | | | | | | | | | | | | | | | | Summary: Hexagon is being updated, but there is not enough to pass these tests. These sections are now on top of Colin's list. Test Plan: Ran changes on hexagon-build-03. Reviewers: colinl, rfoos Reviewed By: rfoos Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D9356 llvm-svn: 236173
* Implemented ASTImporter support for Stmts and fixedSean Callanan2015-04-284-0/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | some bugs in the ASTImporter that this exposed: - When importing functions, the body (if any) was previously ignored. This patch ensures that the body is imported also. - When a function-local Decl is imported, the first thing the ASTImporter does is import its context (via ImportDeclParts()). This can trigger importing the Decl again as part of the body of the function (but only once, since the function's Decl has been added to ImportedDecls). This patch fixes that problem by extending ImportDeclParts() to return the imported Decl if it was imported as part of importing its context, and the patch adds ASTImporter::GetAlreadyImportedOrNull() to support this query. All callers of ImportDeclParts return the imported version of the Decl if ImportDeclParts() returns it. - When creating functions, InnerLocStart of the source function was re-used without importing. This is a straight up bug, and this patch makes ASTImporter import the InnerLocStart and use the imported version. - When importing FileIDs, the ASTImporter previously always tried to re-load the file for the corresponding CacheEntry from disk. This doesn't work if the CacheEntry corresponds to a named memory buffer. This patch changes the code so that if the UniqueID for the cache entry is invalid (i.e., it is not a disk file) the whole entry is treated as if it were invalid, which forces an in-memory copy of the buffer. Also added test cases, using the new support committed in 236011. llvm-svn: 236012
* Ignore test Inputs globally and remove redundant lit.local.cfg filesAlp Toker2013-11-151-1/+0
| | | | | | | | | | By adding a default config.excludes pattern we can avoid individual suppressions in subdirectories. This matches LLVM's lit.cfg which also excludes a few other common non-test filenames for consistency. llvm-svn: 194814
* Changes so that a few tests do not fail when running under guarded malloc.Argyrios Kyrtzidis2013-07-121-1/+1
| | | | | | | Guarded malloc emits some messages at the beginning in stderr when enabled. These messages caused a few tests to fail. llvm-svn: 186219
* Add 'not' to commands that are expected to fail.Rafael Espindola2013-07-0410-10/+10
| | | | | | | This is at least good documentation, but also opens the possibility of using pipefail. llvm-svn: 185652
* Extended VerifyDiagnosticConsumer to also verify source file for diagnostic.Andy Gibbs2013-04-171-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | VerifyDiagnosticConsumer previously would not check that the diagnostic and its matching directive referenced the same source file. Common practice was to create directives that referenced other files but only by line number, and this led to problems such as when the file containing the directive didn't have enough lines to match the location of the diagnostic in the other file, leading to bizarre file formatting and other oddities. This patch causes VerifyDiagnosticConsumer to match source files as well as line numbers. Therefore, a new syntax is made available for directives, for example: // expected-error@file:line {{diagnostic message}} This extends the @line feature where "file" is the file where the diagnostic is generated. The @line syntax is still available and uses the current file for the diagnostic. "file" can be specified either as a relative or absolute path - although the latter has less usefulness, I think! The #include search paths will be used to locate the file and if it is not found an error will be generated. The new check is not optional: if the directive is in a different file to the diagnostic, the file must be specified. Therefore, a number of test-cases have been updated with regard to this. This closes out PR15613. llvm-svn: 179677
* Fix code that attempted to produce a diagnostic with one DiagnosticEngine, thenRichard Smith2012-12-203-0/+13
| | | | | | | | produce a note for that diagnostic either with a different DiagnosticEngine or after calling DiagnosticEngine::Reset(). That didn't make any sense, and did the wrong thing if the original diagnostic was suppressed. llvm-svn: 170636
* Prior to adding the new "expected-no-diagnostics" directive to ↵Andy Gibbs2012-10-191-0/+1
| | | | | | VerifyDiagnosticConsumer, make the necessary adjustment to 580 test-cases which will henceforth require this new directive. llvm-svn: 166280
* Update VerifyDiagnosticConsumer to only get directives during parsing.Jordan Rose2012-08-101-0/+6
| | | | | | | | | | | | | | | | | | | | The old behavior was to re-scan any files (like modules) where we may have directives but won't actually be parsing during the -verify invocation. Now, we keep the old behavior in Debug builds as a sanity check (though modules are a known entity), and expect all legitimate directives to come from comments seen by the preprocessor. This also affects the ARC migration tool, which captures diagnostics in order to filter some out. This change adds an explicit cleanup to CaptureDiagnosticsConsumer in order to let its sub-consumer handle the real end of diagnostics. This was originally split into four patches, but the tests do not run cleanly without all four, so I've combined them into one commit. Patches by Andy Gibbs, with slight modifications from me. llvm-svn: 161650
* Fix crash at @implementation with a forward reference as base class.Argyrios Kyrtzidis2012-03-131-1/+1
| | | | | | rdar://11020003 llvm-svn: 152596
* Improve location fidelity of objc decls.Argyrios Kyrtzidis2011-10-041-4/+4
| | | | | | | | -Add the location of the class name to all objc container decls, not just ObjCInterfaceDecl. -Make objc decls consistent with the rest of the NamedDecls and have getLocation() point to the class name, not the location of '@'. llvm-svn: 141061
* Flip the default for showing include stacks on notes to false. ThisChandler Carruth2011-03-271-1/+1
| | | | | | | | | | | | | required modifying a few tests that specifically use note include stacks to check the source manager's view of include stacks. I've simply added the flag to these tests for now, they may have to be more substantially changed if we decide to remove support for note include stacks altogether. Also, add a test for include stacks on notes that was supposed to go in with the previous commit. llvm-svn: 128390
* Fix two thinkos and add a test for importing the AST of a categoryDouglas Gregor2010-12-083-1/+31
| | | | | | implementation. llvm-svn: 121263
* Implement AST import for Objective-C property implementationsDouglas Gregor2010-12-073-1/+44
| | | | | | (@synthesize and @dynamic). llvm-svn: 121159
* Implement ASTImporter support for Objective-C category implementations.Douglas Gregor2010-12-072-0/+17
| | | | llvm-svn: 121139
* Extern the ASTImporter to import @implementation declarations.Douglas Gregor2010-12-073-1/+46
| | | | llvm-svn: 121097
* Implement AST import support for class template specializations.Douglas Gregor2010-12-013-0/+37
| | | | llvm-svn: 120523
* Implement basic AST importing and merging support for class templateDouglas Gregor2010-11-303-0/+56
| | | | | | declarations. llvm-svn: 120448
* Read/write to/from PCH DeclarationNameLocs, DeclarationNameInfos and ↵Argyrios Kyrtzidis2010-10-151-2/+0
| | | | | | QualifierInfos (rdar://8513756). llvm-svn: 116598
* Try to disable this again.Eric Christopher2010-10-081-3/+5
| | | | llvm-svn: 116094
* Disable this test temporarily in an attempt to green the buildbots.Eric Christopher2010-10-081-3/+3
| | | | llvm-svn: 116082
* Don't add an imported function into its lexical context until *after*Douglas Gregor2010-10-012-0/+8
| | | | | | | we've set all of its parameters. Fixes <rdar://problem/8499598>; thanks to Sean for the diagnosis. llvm-svn: 115387
* Hack in some really terrible C++ record PCH support that I need right now.John McCall2010-06-033-0/+25
| | | | | | | | This is required in order to test: The ASTImporter should set base classes after formally entering the definition. llvm-svn: 105401
* Instead of counting totally diagnostics, split the count into a countChris Lattner2010-04-078-8/+8
| | | | | | | | | | | | | | | of errors and warnings. This allows us to emit something like this: 2 warnings and 1 error generated. instead of: 3 diagnostics generated. This also stops counting 'notes' because they are just follow-on information about the previous diag, not a diagnostic in themselves. llvm-svn: 100675
* Add test for AST importing of C++ namespaces, missing from a prior commitDouglas Gregor2010-02-243-0/+40
| | | | llvm-svn: 97062
* AST import for CStyleCastExpr. With this, we can import Cocoa.h into an ↵Douglas Gregor2010-02-192-2/+4
| | | | | | empty context llvm-svn: 96648
* AST import for sizeof and alignof expressionsDouglas Gregor2010-02-192-2/+4
| | | | llvm-svn: 96647
* AST import for DeclRefExprsDouglas Gregor2010-02-192-2/+4
| | | | llvm-svn: 96646
* AST import of parenthesized expressions, unary operators, binaryDouglas Gregor2010-02-192-2/+6
| | | | | | operators, and compound assignment operators. llvm-svn: 96643
* AST import for character literalsDouglas Gregor2010-02-183-0/+14
| | | | llvm-svn: 96557
* AST import for forward declarations of Objective-C protocolsDouglas Gregor2010-02-182-0/+12
| | | | llvm-svn: 96555
* Implement import of forward declarations of Objective-C classesDouglas Gregor2010-02-182-0/+10
| | | | llvm-svn: 96554
* AST import of Objective-C categories.Douglas Gregor2010-02-183-0/+61
| | | | llvm-svn: 96551
* Implement AST merging for Objective-C properties.Douglas Gregor2010-02-173-0/+34
| | | | llvm-svn: 96483
* AST import for Objective-C protocolsDouglas Gregor2010-02-173-1/+49
| | | | llvm-svn: 96478
* Implement AST importing and checking for Objective-C method declarations.Douglas Gregor2010-02-173-1/+54
| | | | llvm-svn: 96442
* Implement AST importing of Objective-C instance variables. Douglas Gregor2010-02-173-6/+43
| | | | | | Check superclasses when merging two Objective-C @interfaces. llvm-svn: 96420
* Skeleton for importing Objective-C classesDouglas Gregor2010-02-163-0/+20
| | | | llvm-svn: 96306
* Cope with anonymous tags defined within declarators by structurallyDouglas Gregor2010-02-157-1/+32
| | | | | | | | | | | | | | | | | | | | comparing their types under the assumption that they are equivalent, rather than importing the types and then checking for compatibility. A few minor tweaks here: - Teach structural matching to handle compatibility between function types with prototypes and those without prototypes. - Teach structural matching that an incomplete record decl is the same as any other record decl with the same name. - Keep track of pairs of declarations that we have already checked (but failed to find as structurally matching), so we don't emit diagnostics repeatedly. - When importing a typedef of an anonymous tag, be sure to link the imported tag type to its typedef. With these changes, we survive a repeated import of <stdlib.h> and <stdio.h>. Alas, the ASTNodeImporter is getting a little grotty. llvm-svn: 96298
* Reimplement the structural-equality checks used to determine whetherDouglas Gregor2010-02-153-4/+19
| | | | | | | | | | | | | | two types in different AST contexts are equivalent. Rather than transforming the type from one context into the other context, we perform a deep structural comparison of the types. This change addresses a serious problem with recursive data types like struct ListNode { int value; struct ListNode *Next; } xList; llvm-svn: 96278
* Funnel changes to the ImportedDecls list in the ASTImporter through aDouglas Gregor2010-02-122-0/+13
| | | | | | | single Imported function, in preparation for fixing a serious design flaw. llvm-svn: 96044
* Implement AST importing and merging for enumeration types andDouglas Gregor2010-02-123-0/+94
| | | | | | enumerators, along with ImplicitCastExprs to make it work. llvm-svn: 96024
* Handle AST merges of incomplete class types. Douglas Gregor2010-02-122-0/+19
| | | | llvm-svn: 95941
* When AST merging for record declarations fails, warn about theDouglas Gregor2010-02-113-3/+70
| | | | | | | | | | | | | | | | | | | | | | | | | | incompatibility and show where the structural differences are. For example: struct1.c:36:8: warning: type 'struct S7' has incompatible definitions in different translation units struct S7 { int i : 8; unsigned j : 8; } x7; ^ struct1.c:36:33: note: bit-field 'j' with type 'unsigned int' and length 8 here struct S7 { int i : 8; unsigned j : 8; } x7; ^ struct2.c:33:33: note: bit-field 'j' with type 'unsigned int' and length 16 here struct S7 { int i : 8; unsigned j : 16; } x7; ^ There are a few changes to make this work: - ASTImporter now has only a single Diagnostic object, not multiple diagnostic objects. Otherwise, having a warning/error printed via one Diagnostic and its note printed on the other Diagnostic could cause the note to be suppressed. - Implemented import functionality for IntegerLiteral (along with general support for statements and expressions) llvm-svn: 95900
OpenPOWER on IntegriCloud