{
/* Create a bidi string */
base = FRIBIDI_PAR_ON;
-FRIBIDI_GNUC_BEGIN_IGNORE_DEPRECATIONS
+FRIBIDI_BEGIN_IGNORE_DEPRECATIONS
if (!fribidi_log2vis (us, len, &base,
/* output */
out_us, positionVtoL, positionLtoV,
die2
("something failed in fribidi_log2vis.\n"
"perhaps memory allocation failure.", NULL);
-FRIBIDI_GNUC_END_IGNORE_DEPRECATIONS
+FRIBIDI_END_IGNORE_DEPRECATIONS
}
/* stop timer */
if (!char_set_num)
die2 ("unrecognized character set `%s'\n", char_set);
-FRIBIDI_GNUC_BEGIN_IGNORE_DEPRECATIONS
+FRIBIDI_BEGIN_IGNORE_DEPRECATIONS
fribidi_set_mirroring (do_mirror);
fribidi_set_reorder_nsm (do_reorder_nsm);
-FRIBIDI_GNUC_END_IGNORE_DEPRECATIONS
+FRIBIDI_END_IGNORE_DEPRECATIONS
exit_val = 0;
file_found = false;
while (optind < argc || !file_found)
/* Create a bidi string. */
base = input_base_direction;
-FRIBIDI_GNUC_BEGIN_IGNORE_DEPRECATIONS
+FRIBIDI_BEGIN_IGNORE_DEPRECATIONS
log2vis = fribidi_log2vis (logical, len, &base,
/* output */
visual, ltov, vtol, levels);
-FRIBIDI_GNUC_END_IGNORE_DEPRECATIONS
+FRIBIDI_END_IGNORE_DEPRECATIONS
if (log2vis)
{
printf ("%-*s => ", padding_width, S_);
/* Remove explicit marks, if asked for. */
-FRIBIDI_GNUC_BEGIN_IGNORE_DEPRECATIONS
+FRIBIDI_BEGIN_IGNORE_DEPRECATIONS
if (do_clean)
len =
fribidi_remove_bidi_marks (visual, len, ltov, vtol,
levels);
-FRIBIDI_GNUC_END_IGNORE_DEPRECATIONS
+FRIBIDI_END_IGNORE_DEPRECATIONS
if (show_visual)
{
# endif /* !__FRIBIDI_DOC */
# define FRIBIDI_BEGIN_DECLS G_BEGIN_DECLS
# define FRIBIDI_END_DECLS G_END_DECLS
-# define FRIBIDI_GNUC_BEGIN_IGNORE_DEPRECATIONS G_GNUC_BEGIN_IGNORE_DEPRECATIONS
-# define FRIBIDI_GNUC_END_IGNORE_DEPRECATIONS G_GNUC_END_IGNORE_DEPRECATIONS
-#else /* !FRIBIDI_USE_GLIB */
-# define FRIBIDI_GNUC_BEGIN_IGNORE_DEPRECATIONS
-# define FRIBIDI_GNUC_END_IGNORE_DEPRECATIONS
#endif /* !FRIBIDI_USE_GLIB */
+#ifdef __ICC
+#define FRIBIDI_BEGIN_IGNORE_DEPRECATIONS \
+ _Pragma ("warning (push)") \
+ _Pragma ("warning (disable:1478)")
+#define FRIBIDI_END_IGNORE_DEPRECATIONS \
+ _Pragma ("warning (pop)")
+#elif __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 6)
+#define FRIBIDI_BEGIN_IGNORE_DEPRECATIONS \
+ _Pragma ("GCC diagnostic push") \
+ _Pragma ("GCC diagnostic ignored \"-Wdeprecated-declarations\"")
+#define FRIBIDI_END_IGNORE_DEPRECATIONS \
+ _Pragma ("GCC diagnostic pop")
+#elif defined (_MSC_VER) && (_MSC_VER >= 1500)
+#define FRIBIDI_BEGIN_IGNORE_DEPRECATIONS \
+ __pragma (warning (push)) \
+ __pragma (warning (disable : 4996))
+#define FRIBIDI_END_IGNORE_DEPRECATIONS \
+ __pragma (warning (pop))
+#elif defined (__clang__)
+#define FRIBIDI_BEGIN_IGNORE_DEPRECATIONS \
+ _Pragma("clang diagnostic push") \
+ _Pragma("clang diagnostic ignored \"-Wdeprecated-declarations\"")
+#define FRIBIDI_END_IGNORE_DEPRECATIONS \
+ _Pragma("clang diagnostic pop")
+#else
+#define FRIBIDI_BEGIN_IGNORE_DEPRECATIONS
+#define FRIBIDI_END_IGNORE_DEPRECATIONS
+#endif
+
#if defined(__GNUC__) && (__GNUC__ > 2)
# define FRIBIDI_GNUC_WARN_UNUSED __attribute__((__warn_unused_result__))
# define FRIBIDI_GNUC_MALLOC __attribute__((__malloc__))