[Vala] HashTable foreach
- From: "Heikki Paajanen" <hepaajan iki fi>
- To: vala paldo org
- Subject: [Vala] HashTable foreach
- Date: Fri, 24 Nov 2006 14:00:47 +0200 (EET)
Hi,
valac accepts foreach -construct for HashTable but does not seem to
generate any code for it?
"""
using GLib;
public class TestHashTableForeach {
public static int main(string[] args) {
HashTable<string,string> ht = new HashTable(str_hash,str_equal);
ht.insert("test","test");
foreach(string s in ht) {
stdout.printf("Key? %s\n",s);
}
return 0;
}
}
"""
Regards,
Hessu
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]