Skip to content

Commit 4aeecc5

Browse files
use __declspec(deprecated) for deprecated functions on Windows
1 parent 3ef80fd commit 4aeecc5

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

extensions/include/extensions-export.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,10 @@
4040
#endif
4141

4242
#ifndef CMARK_GFM_EXTENSIONS_DEPRECATED
43-
# if !defined(_WIN32)
44-
# define CMARK_GFM_EXTENSIONS_DEPRECATED __attribute__ ((__deprecated__))
43+
# if defined(_WIN32)
44+
# define CMARK_GFM_EXTENSIONS_DEPRECATED __declspec(deprecated)
4545
# else
46-
# define CMARK_GFM_EXTENSIONS_DEPRECATED
46+
# define CMARK_GFM_EXTENSIONS_DEPRECATED __attribute__ ((__deprecated__))
4747
# endif
4848
#endif
4949

src/include/export.h

+3-3
Original file line numberDiff line numberDiff line change
@@ -30,10 +30,10 @@
3030
#endif
3131

3232
#ifndef CMARK_GFM_DEPRECATED
33-
# if !defined(_WIN32)
34-
# define CMARK_GFM_DEPRECATED __attribute__ ((__deprecated__))
33+
# if defined(_WIN32)
34+
# define CMARK_GFM_DEPRECATED __declspec(deprecated)
3535
# else
36-
# define CMARK_GFM_DEPRECATED
36+
# define CMARK_GFM_DEPRECATED __attribute__ ((__deprecated__))
3737
# endif
3838
#endif
3939

0 commit comments

Comments
 (0)