After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 761310 - fix deprecation warning
fix deprecation warning
Status: RESOLVED DUPLICATE of bug 779034
Product: vala
Classification: Core
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: Vala maintainers
Vala maintainers
Depends on:
Blocks:
 
 
Reported: 2016-01-29 21:42 UTC by Ben
Modified: 2017-03-09 09:10 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
patch (1.10 KB, patch)
2016-01-29 21:42 UTC, Ben
none Details | Review

Description Ben 2016-01-29 21:42:09 UTC
Created attachment 320036 [details] [review]
patch

This is the thread-local CodeContext stack used with push() and pop(). The null argument is a destroy_func and is a default arg for new Private()
Comment 1 Luca Bruno 2016-02-24 20:00:14 UTC
How do you use that private? Can you add some context about this change?
Comment 2 Luca Bruno 2016-02-24 21:25:35 UTC
With this new code I get yet another deprecation warning though: warning: ‘g_private_new’ is deprecated
Comment 3 Ben 2016-02-24 21:32:12 UTC
https://developer.gnome.org/glib/stable/glib-Threads.html#G-PRIVATE-INIT:CAPS


"g_private_new has been deprecated since version 2.32 and should not be used in newly-written code. dynamic allocation of GPrivate is a bad idea. Use static storage and G_PRIVATE_INIT() instead."

Can we do this from vala?
Comment 4 Rico Tzschichholz 2017-03-09 09:10:20 UTC

*** This bug has been marked as a duplicate of bug 779034 ***