Rename some stuff in lib/util.rs.

This commit is contained in:
Graydon Hoare 2010-07-05 14:36:39 -07:00
parent 6014384a5d
commit ad61f02d36

View File

@ -1,8 +1,8 @@
type option[T] = tag(none(), some(T)); 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) { alt (opt) {
case (some[T](x)) { case (some[T](x)) {
ret some[U](f[T, U](x)); ret some[U](f[T, U](x));