Hi Che-Liang,
On Oct 4, 2013, at 9:53 PM, Che-Liang Chiou <[email protected]> wrote:
> This patch exposes ref-qualifier information of function type.
> <refqualifier.patch>
+enum CXRefQualifierKind {
+ /** \brief No ref-qualifier was provided. */
+ CXRQ_None = 0,
+ /** \brief An lvalue ref-qualifier was provided (\c &). */
+ CXRQ_LValue,
+ /** \brief An rvalue ref-qualifier was provided (\c &&). */
+ CXRQ_RValue
+};
The general convention used is to repeat the enumerator name without 'kind' in
the enumerators:
enum CXRefQualifierKind {
/** \brief No ref-qualifier was provided. */
CXRefQualifier_None = 0,
/** \brief An lvalue ref-qualifier was provided (\c &). */
CXRefQualifier_LValue,
/** \brief An rvalue ref-qualifier was provided (\c &&). */
CXRefQualifier_RValue
};
+ * \brief Retrieve the ref-qualifier kind of a function or method.
+ *
+ * The ref-qualifier is returned for functions or methods. For other types
+ * CXRQ_None is returned.
+ */
+CINDEX_LINKAGE enum CXRefQualifierKind clang_Type_getRefQualifier(CXType T);
Could you rename it to clang_Type_getCXXRefQualifier and mention in the
comments that this is only relevant for C++ ?
Finally, could you also add some tests for this ?
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits