Home | History | Annotate | Download | only in Sema

Lines Matching defs:Template

1 //===--- ParsedTemplate.h - Template Parsing Data Types ---------*- C++ -*-===//
29 /// \brief Represents the parsed form of a C++ template argument.
32 /// \brief Describes the kind of template argument that was parsed.
34 /// \brief A template type parameter, stored as a type.
36 /// \brief A non-type template parameter, stored as an expression.
38 /// \brief A template template argument, stored as a template name.
39 Template
42 /// \brief Build an empty template argument.
44 /// This template argument is invalid.
47 /// \brief Create a template type argument or non-type template argument.
49 /// \param Arg the template type argument or non-type template argument.
54 /// \brief Create a template template argument.
56 /// \param SS the C++ scope specifier that precedes the template name, if
59 /// \param Template the template to which this template template
62 /// \param TemplateLoc the location of the template name.
64 ParsedTemplateTy Template,
66 : Kind(ParsedTemplateArgument::Template),
67 Arg(Template.getAsOpaquePtr()),
70 /// \brief Determine whether the given template argument is invalid.
73 /// \brief Determine what kind of template argument we have.
76 /// \brief Retrieve the template type argument's type.
78 assert(Kind == Type && "Not a template type argument");
82 /// \brief Retrieve the non-type template argument's expression.
84 assert(Kind == NonType && "Not a non-type template argument");
88 /// \brief Retrieve the template template argument's template name.
90 assert(Kind == Template && "Not a template template argument");
94 /// \brief Retrieve the location of the template argument.
97 /// \brief Retrieve the nested-name-specifier that precedes the template
98 /// name in a template template argument.
100 assert(Kind == Template &&
101 "Only template template arguments can have a scope specifier");
105 /// \brief Retrieve the location of the ellipsis that makes a template
106 /// template argument into a pack expansion.
108 assert(Kind == Template &&
109 "Only template template arguments can have an ellipsis");
113 /// \brief Retrieve a pack expansion of the given template template
123 /// \brief The actual template argument representation, which may be
125 /// expression), or an Sema::TemplateTy (for a template).
128 /// \brief The nested-name-specifier that can accompany a template template
132 /// \brief the location of the template argument.
135 /// \brief The ellipsis location that can accompany a template template
136 /// argument (turning it into a template template argument expansion).
140 /// \brief Information about a template-id annotation
143 /// A template-id annotation token contains the template declaration,
144 /// template arguments, whether those template arguments were types,
145 /// expressions, or template names, and the source locations for important
146 /// tokens. All of the information about template arguments is allocated
152 /// \brief The nested-name-specifier that precedes the template name.
155 /// TemplateKWLoc - The location of the template keyword.
156 /// For e.g. typename T::template Y<U>
159 /// TemplateNameLoc - The location of the template name within the
169 /// The declaration of the template corresponding to the
170 /// template-name.
171 ParsedTemplateTy Template;
173 /// The kind of template that Template refers to.
176 /// The location of the '<' before the template argument
180 /// The location of the '>' after the template argument
184 /// NumArgs - The number of template arguments.
187 /// \brief Retrieves a pointer to the template arguments
231 Template(OpaqueTemplateName), Kind(TemplateKind),
241 /// Retrieves the range of the given template parameter lists.