REP "#2" - multiple set - usefulness (was:Re: REBOL Enhancement Proposa
[1/1] from: geza67::freestart::hu at: 26-Sep-2001 20:46
>> > The logical and straightforward way unfortunately does not work: >> > set [a/b/c d/e] [1 2] >> Just for clarification... >> Could you explain why you would prefer the above SET expression >> to the following? >> a/b/c: 1 d/e: 2
When I have a screen form and I have a database I "spread" field values from the database in "bags", like X to the layout fields Y. After completing the screen form, I "gather" the values in the opposite way. ; db fields x: [i j k] ; screen fields y: [l m n] ; just for didactic purposes :-) - mimicking loading of the db set y [1 2 3] set x reduce y ; mimicking on-screen update of the form set x [4 5 6] ; now the "swap" set y reduce x
> attributes of the object, in constrast to a "c-struct" fashion, > in which other code is free to go in and manipulate the content > of the object.
I use blocks like X,Y for word name repository sets, which I can modify in one place of my code and reuse/reference them several times. -- Best regards, Geza mailto:[geza67--freestart--hu]