Merge branch 'gthread-deprecated' into 'master'

gthread: ignore deprecated declarations in static inline functions

Closes #2094

See merge request GNOME/glib!1472
This commit is contained in:
Philip Withnall 2020-05-07 09:49:50 +00:00
commit ae1003450e

View File

@ -390,12 +390,14 @@ typedef void GRecMutexLocker;
* Returns: a #GRecMutexLocker * Returns: a #GRecMutexLocker
* Since: 2.60 * Since: 2.60
*/ */
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
static inline GRecMutexLocker * static inline GRecMutexLocker *
g_rec_mutex_locker_new (GRecMutex *rec_mutex) g_rec_mutex_locker_new (GRecMutex *rec_mutex)
{ {
g_rec_mutex_lock (rec_mutex); g_rec_mutex_lock (rec_mutex);
return (GRecMutexLocker *) rec_mutex; return (GRecMutexLocker *) rec_mutex;
} }
G_GNUC_END_IGNORE_DEPRECATIONS
/** /**
* g_rec_mutex_locker_free: * g_rec_mutex_locker_free:
@ -407,11 +409,13 @@ g_rec_mutex_locker_new (GRecMutex *rec_mutex)
* *
* Since: 2.60 * Since: 2.60
*/ */
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
static inline void static inline void
g_rec_mutex_locker_free (GRecMutexLocker *locker) g_rec_mutex_locker_free (GRecMutexLocker *locker)
{ {
g_rec_mutex_unlock ((GRecMutex *) locker); g_rec_mutex_unlock ((GRecMutex *) locker);
} }
G_GNUC_END_IGNORE_DEPRECATIONS
/** /**
* GRWLockWriterLocker: * GRWLockWriterLocker:
@ -494,12 +498,14 @@ typedef void GRWLockWriterLocker;
* Returns: a #GRWLockWriterLocker * Returns: a #GRWLockWriterLocker
* Since: 2.62 * Since: 2.62
*/ */
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
static inline GRWLockWriterLocker * static inline GRWLockWriterLocker *
g_rw_lock_writer_locker_new (GRWLock *rw_lock) g_rw_lock_writer_locker_new (GRWLock *rw_lock)
{ {
g_rw_lock_writer_lock (rw_lock); g_rw_lock_writer_lock (rw_lock);
return (GRWLockWriterLocker *) rw_lock; return (GRWLockWriterLocker *) rw_lock;
} }
G_GNUC_END_IGNORE_DEPRECATIONS
/** /**
* g_rw_lock_writer_locker_free: * g_rw_lock_writer_locker_free:
@ -512,11 +518,13 @@ g_rw_lock_writer_locker_new (GRWLock *rw_lock)
* *
* Since: 2.62 * Since: 2.62
*/ */
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
static inline void static inline void
g_rw_lock_writer_locker_free (GRWLockWriterLocker *locker) g_rw_lock_writer_locker_free (GRWLockWriterLocker *locker)
{ {
g_rw_lock_writer_unlock ((GRWLock *) locker); g_rw_lock_writer_unlock ((GRWLock *) locker);
} }
G_GNUC_END_IGNORE_DEPRECATIONS
/** /**
* GRWLockReaderLocker: * GRWLockReaderLocker:
@ -543,12 +551,14 @@ typedef void GRWLockReaderLocker;
* Returns: a #GRWLockReaderLocker * Returns: a #GRWLockReaderLocker
* Since: 2.62 * Since: 2.62
*/ */
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
static inline GRWLockReaderLocker * static inline GRWLockReaderLocker *
g_rw_lock_reader_locker_new (GRWLock *rw_lock) g_rw_lock_reader_locker_new (GRWLock *rw_lock)
{ {
g_rw_lock_reader_lock (rw_lock); g_rw_lock_reader_lock (rw_lock);
return (GRWLockReaderLocker *) rw_lock; return (GRWLockReaderLocker *) rw_lock;
} }
G_GNUC_END_IGNORE_DEPRECATIONS
/** /**
* g_rw_lock_reader_locker_free: * g_rw_lock_reader_locker_free:
@ -561,11 +571,13 @@ g_rw_lock_reader_locker_new (GRWLock *rw_lock)
* *
* Since: 2.62 * Since: 2.62
*/ */
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
static inline void static inline void
g_rw_lock_reader_locker_free (GRWLockReaderLocker *locker) g_rw_lock_reader_locker_free (GRWLockReaderLocker *locker)
{ {
g_rw_lock_reader_unlock ((GRWLock *) locker); g_rw_lock_reader_unlock ((GRWLock *) locker);
} }
G_GNUC_END_IGNORE_DEPRECATIONS
G_END_DECLS G_END_DECLS