As long as you avoid name collisions with any other implicit on Array (e.g. ArrayOps in 2.8, which adds collection methods), you can expand using the regular implicit pimp-my-library template:
class FooArray[T](at: Array[T]) { def foo() = at.length*at.length } implicit def array2foo[T](at: Array[T]) = new FooArray(at) scala> Array(1,2,3).foo res2: Int = 9
source share