summaryrefslogtreecommitdiffstats
path: root/clang/test/SemaTemplate/default-arguments.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Add a null check that fixes the crash in PR4362, and make sure to ↵Anders Carlsson2009-06-111-0/+9
| | | | | | instantiate non-type template arguments. llvm-svn: 73193
* Fix another crash and actually make the test case work.Anders Carlsson2009-06-051-1/+1
| | | | llvm-svn: 72913
* Fix a case when the TemplateArgs vector can be empty.Anders Carlsson2009-06-051-0/+3
| | | | llvm-svn: 72911
* Rename clang to clang-cc.Daniel Dunbar2009-03-241-1/+1
| | | | | | Tests and drivers updated, still need to shuffle dirs. llvm-svn: 67602
* Implement parsing of nested-name-specifiers that involve template-ids, e.g.,Douglas Gregor2009-02-251-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | std::vector<int>::allocator_type When we parse a template-id that names a type, it will become either a template-id annotation (which is a parsed representation of a template-id that has not yet been through semantic analysis) or a typename annotation (where semantic analysis has resolved the template-id to an actual type), depending on the context. We only produce a type in contexts where we know that we only need type information, e.g., in a type specifier. Otherwise, we create a template-id annotation that can later be "upgraded" by transforming it into a typename annotation when the parser needs a type. This occurs, for example, when we've parsed "std::vector<int>" above and then see the '::' after it. However, it means that when writing something like this: template<> class Outer::Inner<int> { ... }; We have two tokens to represent Outer::Inner<int>: one token for the nested name specifier Outer::, and one template-id annotation token for Inner<int>, which will be passed to semantic analysis to define the class template specialization. Most of the churn in the template tests in this patch come from an improvement in our error recovery from ill-formed template-ids. llvm-svn: 65467
* Allow the use of default template arguments when forming a classDouglas Gregor2009-02-111-0/+13
template specialization (e.g., std::vector<int> would now be well-formed, since it relies on a default argument for the Allocator template parameter). This is much less interesting than one might expect, since (1) we're not actually using the default arguments for anything important, such as naming an actual Decl, and (2) we'll often need to instantiate the default arguments to check their well-formedness. The real fun will come later. llvm-svn: 64310
OpenPOWER on IntegriCloud