How about this quick one?
block: ["anybody" [test1 [1 [1 2] 2 [1 5]]]]
selection-block: ["anybody" 'test1 2]
select-deep: func [
blk [block!] sel-blk [block!] /local v
][
v: select block first sel-blk
foreach item next sel-blk [
probe v
v: select v item
]
return v
]
select-deep block selection-block
> Hi Andrew,
>
> Thanks for suggesting, but IMHO I think the approach I proposed should be
> more robust for multi-type nested structures:
>
> Let's say:
>
> >> c: ["anybody" [test1 [1 [1 2] 2 [1 5]]]]
> >> c/"anybody"/test1
> ** Syntax Error: Invalid path -- c/.
> ** Where: (line 1) c/"anybody"/test1
> >> select-deep c "anybody" 'test1
> == [1 [1 2] 2 [1 5]]
>
> But in order to allow this, you have to modify my function's header in :
>
> select-deep: func [
> data [block!]
> arg1 [any-type!]
> arg2 [any-type! unset!]
> arg3 [any-type! unset!]
> arg4 [any-type! unset!]
> arg5 [any-type! unset!]
> ][...]
>
> Your idea ?
--
To unsubscribe from this list, please send an email to
[EMAIL PROTECTED] with "unsubscribe" in the
subject, without the quotes.