Skip to content

Commit

Permalink
Add macro to mark unimplemented functions and methods
Browse files Browse the repository at this point in the history
  • Loading branch information
rfm committed Nov 21, 2023
1 parent 270429c commit 5917e32
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 1 deletion.
6 changes: 6 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
2023-11-21 Richard Frith-Macdonald <rfm@gnu.org>

* Headers/GNUstepBase/GSVersionMacros.h: Added GS_UNIMPLEMENTED to
mark methods and functions as unimplemented for compiler warnings
and documentation. github #350

2023-11-14 Frederik Seiffert <frederik@algoriddim.com>

* Source/NSURLRequest.m: Support deleting NSMutableURLRequest headers by
Expand Down
11 changes: 10 additions & 1 deletion Headers/GNUstepBase/GSVersionMacros.h
Original file line number Diff line number Diff line change
Expand Up @@ -242,11 +242,20 @@
*/

#if defined(__clang__) || GS_GCC_MINREQ(3,1)
# define GS_DEPRECATED_FUNC __attribute__ ((deprecated))
# define GS_DEPRECATED_FUNC __attribute__((deprecated))
#else
# define GS_DEPRECATED_FUNC
#endif

/* This attribute is placed immediately before the name of a method
* or function to mark it as unimplemented.
*/
#if defined(__clang__) || GS_GCC_MINREQ(3,1)
# define GS_UNIMPLEMENTED __attribute__((deprecated("*** not implemented - please contribute an implementation before using this feature ***")))
#else
# define GS_UNIMPLEMENTED
#endif

#define GS_UNUSED_ARG __attribute__((unused))

#define GS_UNUSED_FUNC __attribute__((unused))
Expand Down

0 comments on commit 5917e32

Please sign in to comment.