Re: [Vala] shouldn't be sizeof expression is a constant?
- From: Jonathan Ryan <jryan curious-os com>
- To: vala-list gnome org
- Subject: Re: [Vala] shouldn't be sizeof expression is a constant?
- Date: Sun, 27 Mar 2011 15:30:06 -0400
On 03/27/2011 03:26 PM, Maga Abdurakhmanov wrote:
Hi!
const int c = sizeof(int);
this code is not compiled. Why? It's allowed in C
_______________________________________________
vala-list mailing list
vala-list gnome org
http://mail.gnome.org/mailman/listinfo/vala-list
My vala is expecting a ulong.
Also sizeof apparently isn't considered a constant in Vala. Which means
you cannot use const. This works for me:
ulong c = sizeof(int);
--
Jonathan Ryan
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]