import * from hashset; syntax set_initialization from "<" Arg(, type) ">{" [{Arg(, elems) "," [s]} Arg(, elems)] "}" { let res = hashset<$type>(); @elems.i { res.add($elems.i); } return move(res); } syntax set_comprehension from "{" [s] Arg(, map) s "for" s Arg(, it) [s] ":" [s] Arg(, type) s "in" s Arg(, container) [s] "}" { let res = hashset<$type>(); let func = ($it: $type) -> $type $map; for _it_ in $container { res.add(func(*_it_)); \} return move(res); }