Following upgrading to Vala verion 0.15.2, I get the warning
'GLib.Thread.create
has been deprecated since 2.32. Use new Thread<T> ()'. So I did as it
suggested,
but then I get the errors as follows:
In function ?thread_demo_main?:
warning: assignment makes pointer from integer without a cast [enabled by
default]
undefined reference to `g_thread_new'
undefined reference to `g_thread_free'
An example of code to recreate these errors is as follows:
public class ThreadDemo {
public static void main (string [] args) {
ThreadDemo demo = new ThreadDemo();
Thread<void*> thread_a = new Thread<void*>
(null, demo.thread_func);
thread_a.join ();
}
public void* thread_func () {
print ("hello from the thread function.\n");
void* ret = null;
return ret;
}
}
Is this a bug in Vala or am I phrasing the call incorrectly?
Thanks,
David
_______________________________________________
vala-list mailing list
[email protected]
http://mail.gnome.org/mailman/listinfo/vala-list