Rename some stuff in lib/util.rs.
This commit is contained in:
parent
6014384a5d
commit
ad61f02d36
@ -1,8 +1,8 @@
|
||||
type option[T] = tag(none(), some(T));
|
||||
|
||||
type map[T, U] = fn(&T) -> U;
|
||||
type operator[T, U] = fn(&T) -> U;
|
||||
|
||||
fn option_map[T, U](map[T, U] f, &option[T] opt) -> option[U] {
|
||||
fn option_map[T, U](&operator[T, U] f, &option[T] opt) -> option[U] {
|
||||
alt (opt) {
|
||||
case (some[T](x)) {
|
||||
ret some[U](f[T, U](x));
|
||||
|
Loading…
Reference in New Issue
Block a user