Skip to content

Commit

Permalink
FEAT: allow select on module
Browse files Browse the repository at this point in the history
  • Loading branch information
Oldes committed Nov 18, 2021
1 parent 067fee5 commit cfe7e2a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/boot/actions.reb
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ find: action [

select: action [
{Searches for a value; returns the value that follows, else none.}
series [series! port! map! object! none!]
series [series! port! map! object! module! none!]
value [any-type!]
/part {Limits the search to a given length or position}
length [number! series! pair!]
Expand Down
5 changes: 5 additions & 0 deletions src/tests/units/module-test.r3
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,11 @@ supplement system/options/module-paths join what-dir %units/files/
unset? :system/contexts/user/b
none? system/contexts/user/c
]
--test-- "select"
;@@ https://github.com/Oldes/Rebol-issues/issues/1380
m: module [] [a: 1]
--assert 1 = select m 'a
--assert none? select m 'b


===end-group===
Expand Down

0 comments on commit cfe7e2a

Please sign in to comment.