Home | History | Annotate | Download | only in AST

Lines Matching defs:Template

1 //===--- TemplateName.h - C++ Template Name Representation-------*- C++ -*-===//
41 /// template names or an already-substituted template template parameter pack.
54 /// \brief The number of stored templates or template arguments,
92 /// overloaded template name.
113 /// \brief A structure for storing an already-substituted template template
116 /// This kind of template names occurs when the parameter pack has been
117 /// provided with a template template argument pack in a context where its
132 /// \brief Retrieve the template template parameter pack being substituted.
137 /// \brief Retrieve the template template argument pack with which this
149 /// \brief Represents a C++ template name within the type system.
151 /// A C++ template name refers to a template within the C++ type
152 /// system. In most cases, a template name is simply a reference to a
153 /// class template, e.g.
156 /// template<typename T> class X { };
161 /// Here, the 'X' in \c X<int> is a template name that refers to the
162 /// declaration of the class template X, above. Template names can
163 /// also refer to function templates, C++0x template aliases, etc.
165 /// Some template names are dependent. For example, consider:
168 /// template<typename MetaFun, typename T1, typename T2> struct apply2 {
169 /// typedef typename MetaFun::template apply<T1, T2>::type type;
173 /// Here, "apply" is treated as a template name within the typename
174 /// specifier in the typedef. "apply" is a nested template, and can
189 /// \brief A single template declaration.
190 Template,
191 /// \brief A set of overloaded template declarations.
193 /// \brief A qualified template name, where the qualification is kept
196 /// \brief A dependent template name that has not been resolved to a
197 /// template (or set of templates).
199 /// \brief A template template parameter that has been substituted
200 /// for some other template name.
202 /// \brief A template template parameter pack that has been substituted for
203 /// a template template argument pack, but has not yet been expanded into
209 explicit TemplateName(TemplateDecl *Template);
216 /// \brief Determine whether this template name is NULL.
222 /// \brief Retrieve the underlying template declaration that
223 /// this template name refers to, if known.
225 /// \returns The template declaration that this template name refers
226 /// to, if any. If the template name does not refer to a specific
231 /// \brief Retrieve the underlying, overloaded function template
232 // declarations that this template name refers to, if known.
234 /// \returns The set of overloaded function templates that this template
235 /// name refers to, if known. If the template name does not refer to a
237 /// refers to a single template, returns NULL.
240 /// \brief Retrieve the substituted template template parameter, if
243 /// \returns The storage for the substituted template template parameter,
247 /// \brief Retrieve the substituted template template parameter pack, if
250 /// \returns The storage for the substituted template template parameter pack,
255 /// \brief Retrieve the underlying qualified template name
259 /// \brief Retrieve the underlying dependent template name
265 /// \brief Determines whether this is a dependent template name.
268 /// \brief Determines whether this is a template name that somehow
269 /// depends on a template parameter.
272 /// \brief Determines whether this template name contains an
276 /// \brief Print the template name.
278 /// \param OS the output stream to which the template name will be
282 /// nested-name-specifier that precedes the template name (if it has
287 /// \brief Debugging aid that dumps the template name.
290 /// \brief Debugging aid that dumps the template name to standard
298 /// \brief Retrieve the template name as a void pointer.
301 /// \brief Build a template name from a void pointer.
313 /// substituted template template parameter.
344 /// \brief Represents a template name that was expressed as a
347 /// This kind of template name refers to a template name that was
349 /// the nested name specifier is "std::" and the template name is the
351 /// used to provide "sugar" for template names that were expressed
356 /// \brief The nested name specifier that qualifies the template name.
358 /// The bit is used to indicate whether the "template" keyword was
359 /// present before the template name itself. Note that the
360 /// "template" keyword is always redundant in this case (otherwise,
361 /// the template name would be a dependent name and we would express
365 /// \brief The template declaration or set of overloaded function templates
367 TemplateDecl *Template;
372 TemplateDecl *Template)
374 Template(Template) { }
380 /// \brief Whether the template name was prefixed by the "template"
384 /// \brief The template declaration that this qualified name refers
386 TemplateDecl *getDecl() const { return Template; }
388 /// \brief The template declaration to which this qualified name
390 TemplateDecl *getTemplateDecl() const { return Template; }
397 bool TemplateKeyword, TemplateDecl *Template) {
400 ID.AddPointer(Template);
404 /// \brief Represents a dependent template name that cannot be
405 /// resolved prior to template instantiation.
407 /// This kind of template name refers to a dependent template name,
409 /// DependentTemplateName can refer to "MetaFun::template apply",
411 /// template name referenced. The "template" keyword is implied.
413 /// \brief The nested name specifier that qualifies the template
421 /// \brief The dependent template name.
423 /// \brief The identifier template name.
434 /// \brief The canonical template name to which this dependent
435 /// template name refers.
437 /// The canonical template name for a dependent template name is
438 /// another dependent template name whose nested name specifier is
470 /// \brief Determine whether this template name refers to an identifier.
473 /// \brief Returns the identifier to which this template name refers.
475 assert(isIdentifier() && "Template name isn't an identifier?");
479 /// \brief Determine whether this template name refers to an overloaded
483 /// \brief Return the overloaded operator to which this template name refers.
486 "Template name isn't an overloaded operator?");
517 template<>