[REBOL] Associative data store Re:(3)
From: rebol:keithdevens at: 14-Sep-2000 19:13
I really like the path idea. Is there any way to emulate an associative
array without having to make a special object type?
Very unfortunately, Rebol doesn't let you just do things like:
assoc/key: "value"
(if assoc/key doesn't actually exist yet)
is there any way to cheat and do something like:
(fake example that doesn't work)
assoc: make hash! []
change assoc/key "dude"
--------------------------------------------------------------------
It would be really really nice if RT could give us something like this (hint
hint):
assoc: make associative! []
assoc/key: "value"
'first could give us the keys
and 'second could give us the values
Bonus is, it doesn't require any new syntax... no funky assoc{'key'} or
anything. :)
Keith