mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-02-04 02:06:18 +01:00
gdate: Deprecate GTime
It’s not Y2038-safe, as it’s 32-bit. While it was previously deprecated in the documentation, now add the deprecation annotation for the compiler. Signed-off-by: Philip Withnall <withnall@endlessm.com> Helps: #1438
This commit is contained in:
parent
dbabd2b8a7
commit
5983cc8742
@ -1447,12 +1447,14 @@ g_date_set_time_t (GDate *date,
|
||||
*
|
||||
* Deprecated: 2.10: Use g_date_set_time_t() instead.
|
||||
*/
|
||||
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
|
||||
void
|
||||
g_date_set_time (GDate *date,
|
||||
GTime time_)
|
||||
{
|
||||
g_date_set_time_t (date, (time_t) time_);
|
||||
}
|
||||
G_GNUC_END_IGNORE_DEPRECATIONS
|
||||
|
||||
/**
|
||||
* g_date_set_time_val:
|
||||
|
@ -45,7 +45,7 @@ G_BEGIN_DECLS
|
||||
* Pennington <hp@pobox.com>
|
||||
*/
|
||||
|
||||
typedef gint32 GTime;
|
||||
typedef gint32 GTime GLIB_DEPRECATED_TYPE_IN_2_62_FOR(GDateTime);
|
||||
typedef guint16 GDateYear;
|
||||
typedef guint8 GDateDay; /* day of the month */
|
||||
typedef struct _GDate GDate;
|
||||
@ -198,9 +198,11 @@ void g_date_set_time_t (GDate *date,
|
||||
GLIB_AVAILABLE_IN_ALL
|
||||
void g_date_set_time_val (GDate *date,
|
||||
GTimeVal *timeval);
|
||||
G_GNUC_BEGIN_IGNORE_DEPRECATIONS
|
||||
GLIB_DEPRECATED_FOR(g_date_set_time_t)
|
||||
void g_date_set_time (GDate *date,
|
||||
GTime time_);
|
||||
G_GNUC_END_IGNORE_DEPRECATIONS
|
||||
GLIB_AVAILABLE_IN_ALL
|
||||
void g_date_set_month (GDate *date,
|
||||
GDateMonth month);
|
||||
|
Loading…
Reference in New Issue
Block a user