@@ -18,18 +18,31 @@ #import "OFEnumerator.h" #import "OFSerialization.h" OF_ASSUME_NONNULL_BEGIN +/** @file */ + +/* + * Make clang's -Wdocumentation shut about about using @struct on someting it + * thinks is not a struct. Doxygen requires it this way. + */ +#ifdef __clang__ +# pragma clang diagnostic push +# pragma clang diagnostic ignored "-Wdocumentation" +#endif /** - * @typedef OFListItem OFList.h ObjFW/OFList.h + * @struct OFListItem OFList.h ObjFW/OFList.h * * @brief A list item. * * See @ref OFListItemNext, @ref OFListItemPrevious and @ref OFListItemObject. */ -typedef struct OFListItem *OFListItem; +typedef struct _OFListItem *OFListItem; +#ifdef __clang__ +# pragma clang diagnostic pop +#endif #ifdef __cplusplus extern "C" { #endif /*! @@ -36,20 +49,20 @@ * @brief Returns the next list item of the list item. * * @param listItem The list item for which the next list item should be returned * @return The next list item of the list item */ -OFListItem OFListItemNext(OFListItem _Nonnull listItem); +extern OFListItem _Nullable OFListItemNext(OFListItem _Nonnull listItem); /*! * @brief Returns the previous list item of the list item. * * @param listItem The list item for which the previous list item should be * returned * @return The previous list item of the list item */ -OFListItem OFListItemPrevious(OFListItem _Nonnull listItem); +extern OFListItem _Nullable OFListItemPrevious(OFListItem _Nonnull listItem); /*! * @brief Returns the object of the list item. * * @warning The returned object is not retained and autoreleased - this is the @@ -56,11 +69,11 @@ * caller's responsibility! * * @param listItem The list item for which the object should be returned * @return The object of the list item */ -id OFListItemObject(OFListItem _Nonnull listItem); +extern id _Nonnull OFListItemObject(OFListItem _Nonnull listItem); #ifdef __cplusplus } #endif /**