fx.collections: update iterator semantics
This commit is contained in:
@@ -19,13 +19,13 @@ int main(void)
|
||||
printf("no value\n");
|
||||
}
|
||||
|
||||
fx_iterator *it = fx_hashtable_begin(ht);
|
||||
const fx_iterator *it = fx_hashtable_begin(ht);
|
||||
fx_foreach(val, it)
|
||||
{
|
||||
fx_hashtable_item *item = NULL;
|
||||
fx_value_get_object(&val, &item);
|
||||
fx_value_get_object(val, &item);
|
||||
printf("item %p\n", item);
|
||||
fx_value key, value;
|
||||
const fx_value *key, *value;
|
||||
key = fx_hashtable_item_get_key(item);
|
||||
value = fx_hashtable_item_get_value(item);
|
||||
|
||||
@@ -34,10 +34,10 @@ int main(void)
|
||||
fx_foreach(prop_val, prop_it)
|
||||
{
|
||||
fx_property *prop;
|
||||
fx_value_get_object(&prop_val, &prop);
|
||||
fx_value_get_object(prop_val, &prop);
|
||||
printf("%s = ", fx_property_get_name(prop));
|
||||
fx_value value = FX_VALUE_EMPTY;
|
||||
fx_property_get_value(prop, &val, &value);
|
||||
fx_property_get_value(prop, val, &value);
|
||||
fx_value_to_string(&value, fx_stdout, NULL);
|
||||
printf("\n");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user