@@ -34,19 +34,15 @@ /*! * @class OFMutableDictionary OFDictionary.h ObjFW/OFDictionary.h * * @brief An abstract class for storing and changing objects in a dictionary. */ -#ifdef OF_HAVE_GENERICS -@interface OFMutableDictionary: - OFDictionary -#else -# ifndef DOXYGEN -# define KeyType id -# define ObjectType id -# endif -@interface OFMutableDictionary: OFDictionary +@interface OFMutableDictionary OF_GENERIC(KeyType, ObjectType): + OFDictionary OF_GENERIC(KeyType, ObjectType) +#if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) +# define KeyType id +# define ObjectType id #endif /*! * @brief Creates a new OFMutableDictionary with enough memory to hold the * specified number of objects. * @@ -108,12 +104,12 @@ /*! * @brief Converts the mutable dictionary to an immutable dictionary. */ - (void)makeImmutable; -@end #if !defined(OF_HAVE_GENERICS) && !defined(DOXYGEN) # undef KeyType # undef ObjectType #endif +@end OF_ASSUME_NONNULL_END