summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema
Commit message (Collapse)AuthorAgeFilesLines
* Fix for PR4382: allow instantiating dependent nested name specifiers. Eli Friedman2009-06-131-1/+1
| | | | | | | | I'm not completely sure this is the right way to fix this issue, but it seems reasonable, and it's consistent with the non-template code for this construct. llvm-svn: 73285
* More work on type parameter packs.Anders Carlsson2009-06-131-3/+24
| | | | llvm-svn: 73281
* Remove a bunch of unnecessary template argument deduction code that wasDouglas Gregor2009-06-131-159/+15
| | | | | | obviously written by someone who didn't read C++ [temp.class.spec]. llvm-svn: 73276
* Move template type argument checking out into a separate function. No ↵Anders Carlsson2009-06-132-21/+33
| | | | | | functionality change. llvm-svn: 73275
* When some template parameters of a class template partialDouglas Gregor2009-06-133-3/+211
| | | | | | | specialization cannot be deduced, produce a warning noting that the affected class template partial specialization will never be used. llvm-svn: 73274
* A parameter pack must always come last in a class template.Anders Carlsson2009-06-121-1/+18
| | | | llvm-svn: 73269
* No need to mark the parameter as invalid, just ignore the default argument.Anders Carlsson2009-06-121-1/+0
| | | | llvm-svn: 73268
* add the location of the ')' in a do/while statement to DoStmt.Chris Lattner2009-06-123-4/+7
| | | | | | This fixes a source range problem reported by Olaf Krzikalla. llvm-svn: 73266
* Address comments from Doug - Add a Sema::SemaRef.BuildBlockPointerType and ↵Anders Carlsson2009-06-124-9/+34
| | | | | | use it. llvm-svn: 73264
* It looks like we've finished off matching of class template partial ↵Douglas Gregor2009-06-122-7/+31
| | | | | | specializations; add comments and update the C++ status page llvm-svn: 73263
* Parameter packs can't have default arguments.Anders Carlsson2009-06-121-0/+9
| | | | llvm-svn: 73262
* Keep track of whether a type parameter is actually a type parameter pack.Anders Carlsson2009-06-121-1/+2
| | | | llvm-svn: 73261
* Finish implementing checking of class template partial specializationsDouglas Gregor2009-06-123-7/+17
| | | | llvm-svn: 73260
* Diagnose C++ [temp.class.spec]p9b3, where a class template partialDouglas Gregor2009-06-122-8/+83
| | | | | | | | | specialization's arguments are identical to the implicit template arguments of the primary template. Typically, this is meant to be a declaration/definition of the primary template, so we give that advice. llvm-svn: 73259
* Diagnose the incorrect use of non-type template arguments for classDouglas Gregor2009-06-123-0/+79
| | | | | | template partial specializations. llvm-svn: 73254
* Parse support for C++0x type parameter packs.Anders Carlsson2009-06-122-2/+4
| | | | llvm-svn: 73247
* Verify that the template parameters of a class template partialDouglas Gregor2009-06-121-4/+42
| | | | | | | specialization do not have default arguments (C++ [temp.class.spec]p10). llvm-svn: 73245
* Fix PR4365.Anders Carlsson2009-06-121-0/+6
| | | | llvm-svn: 73240
* Improve template argument deduction to keep track of why templateDouglas Gregor2009-06-123-194/+467
| | | | | | | | | | | | | | | | argument deduction failed. For example, given template<typename T> struct is_same<T, T> { ... }; template argument deduction will fail for is_same<int, float>, and now reports enough information Right now, we don't do anything with this extra information, but it can be used for informative diagnostics that say, e.g., "template argument deduction failed because T was deduced to 'int' in one context and 'float' in another". llvm-svn: 73237
* It's an error to use a function declared in a class definition as a default ↵Anders Carlsson2009-06-123-5/+30
| | | | | | argument before the function has been declared. llvm-svn: 73234
* Deducation and instantiation of block types.Anders Carlsson2009-06-122-3/+22
| | | | llvm-svn: 73232
* Once we have deduced the template arguments of a class templateDouglas Gregor2009-06-114-82/+189
| | | | | | | | | | | | partial specialization, substitute those template arguments back into the template arguments of the class template partial specialization to see if the results still match the original template arguments. This code is more general than it needs to be, since we don't yet diagnose C++ [temp.class.spec]p9. However, it's likely to be needed for function templates. llvm-svn: 73196
* Add a null check that fixes the crash in PR4362, and make sure to ↵Anders Carlsson2009-06-111-3/+17
| | | | | | instantiate non-type template arguments. llvm-svn: 73193
* Make sure to calculate value-dependence correctly when deal with ICEs. Eli Friedman2009-06-111-1/+6
| | | | | | | | (Actually, this isn't precisely correct, but it doesn't make sense to query whether an expression that isn't an ICE is value-dependent anyway.) llvm-svn: 73179
* Separate TemplateArgument instantiation logic into its own function. No ↵Douglas Gregor2009-06-112-30/+41
| | | | | | functionality change. llvm-svn: 73176
* Template argument deduction for member pointers.Douglas Gregor2009-06-103-1/+103
| | | | | | | Also, introduced some of the framework for performing instantiation as part of template argument deduction. llvm-svn: 73175
* PR4350: Make sure we don't create invalid printf attributes. This isn't Eli Friedman2009-06-101-3/+5
| | | | | | | | visible anywhere normally because the printf format checks for this case, and we don't print out attribute values anywhere. Original patch by Roberto Bagnara. llvm-svn: 73157
* Handle member pointer types with dependent class types (e.g., intDouglas Gregor2009-06-093-46/+91
| | | | | | T::*) and implement template instantiation for member pointer types. llvm-svn: 73151
* Implement template argument deduction for class templateDouglas Gregor2009-06-091-0/+102
| | | | | | | | specialization types. As the example shows, we can now compute the length of a type-list using a template metaprogram and class template partial specialization. llvm-svn: 73136
* Add more parser support for Microsoft extensions.Eli Friedman2009-06-081-0/+3
| | | | llvm-svn: 73101
* Address comments from Doug.Anders Carlsson2009-06-081-3/+10
| | | | llvm-svn: 73077
* Document the template argument deduction patterns that Anders' patch supportsDouglas Gregor2009-06-081-0/+3
| | | | llvm-svn: 73071
* Template argument deduction for function types.Anders Carlsson2009-06-081-0/+31
| | | | llvm-svn: 73070
* Delete method which is now trivial.Eli Friedman2009-06-081-4/+4
| | | | llvm-svn: 73043
* Don't allow defining a block with a non-prototype type. Remove a Eli Friedman2009-06-081-1/+1
| | | | | | | | | | hack which introduces some strange inconsistencies in compatibility for block pointers. Note that unlike an earlier revision proposed on cfe-commits, this patch still allows declaring block pointers without a prototype. llvm-svn: 73041
* Instantiation support for more Obj-C expressions, string literals, @selector ↵Anders Carlsson2009-06-071-7/+4
| | | | | | and @protocol expressions. llvm-svn: 73036
* Template instantiation support for Obj-C @encode expressions.Anders Carlsson2009-06-073-16/+39
| | | | llvm-svn: 73034
* Adds synthesize ivars to DeclContext.Fariborz Jahanian2009-06-061-1/+6
| | | | llvm-svn: 73000
* Make ParmVarDecl::getDefaultArg() more robust, it now asserts that the ↵Anders Carlsson2009-06-061-1/+1
| | | | | | argument is not unparsed. Add a new hasDefaultArg() and use it in places where getDefaultArg() was called when the argument was unparsed. llvm-svn: 72984
* Default builtin creation to off; we don't really want to be doing it Eli Friedman2009-06-061-2/+2
| | | | | | | without a relevant source location anyway. Fixes the issue with weird warnings when including objc/Object.h on OS X. llvm-svn: 72978
* Use of DeclContext for objc's ivars. No functionalityFariborz Jahanian2009-06-052-9/+27
| | | | | | change. More to follow. llvm-svn: 72951
* Improvements to CXXExprWithTemporaries in preparation for fixing a bug with ↵Anders Carlsson2009-06-052-8/+24
| | | | | | default arguments that have temporaries. llvm-svn: 72944
* Address review comments for #pragma weak.Eli Friedman2009-06-052-2/+3
| | | | llvm-svn: 72926
* Make TemplateArgumentListBuilder take an ASTContext (because we're probably ↵Anders Carlsson2009-06-052-4/+4
| | | | | | going to need it later). Move push_back to the .cpp file. If the passed in template argument is a type, assert that it's canonical. llvm-svn: 72918
* Make the TemplateArgumentList take a TemplateArgumentListBuilder.Anders Carlsson2009-06-052-10/+14
| | | | llvm-svn: 72917
* Change the specialization decls to take a TemplateArgumentListBuilder.Anders Carlsson2009-06-051-17/+10
| | | | llvm-svn: 72916
* Add a helper class for building template argument lists.Anders Carlsson2009-06-052-39/+45
| | | | llvm-svn: 72915
* Fix another crash and actually make the test case work.Anders Carlsson2009-06-051-1/+1
| | | | llvm-svn: 72913
* Start of a Sema implementation for #pragma weak. This isn't really theEli Friedman2009-06-052-1/+43
| | | | | | right approach, but I'm still not sure what the best way to go about this is. llvm-svn: 72912
* Fix a case when the TemplateArgs vector can be empty.Anders Carlsson2009-06-051-1/+1
| | | | llvm-svn: 72911
OpenPOWER on IntegriCloud