[Vala] Switch statement on GType.
- From: Sam Danielson <samdanielson gmail com>
- To: Vala ML <vala-list gnome org>
- Subject: [Vala] Switch statement on GType.
- Date: Sat, 20 Jun 2009 09:34:22 -0700
Under Vala 0.6 the following worked.
switch (tree_store.get_column_type (n)) {
case typeof(string):
...
break;
}
In Vala 0.7 it does not -- error: Integer or string expression expected.
But GLib.Type derives from ulong so this seems to violate the Liskov
substitution principle. Is this a bug or desired behavior?
-Sam Danielson
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]