 public struct _prext_LazySequence<Base_ : SequenceType>
   : _prext_LazySequenceType, _SequenceWrapperType {
   public var _base: Base_
+  public var elements: Base_ { return _base }
 }
 
 extension SequenceType {

//===--- Sequences --------------------------------------------------------===//

/// A `SequenceType` whose elements consist of those in a `Base`
/// `SequenceType` passed through a transform function returning `T`.
/// These elements are computed lazily, each time they're read, by
/// calling the transform function on a base element.
public struct _prext_MapSequence<Base : SequenceType, T>
  : _prext_LazySequenceType, _SequenceWrapperType {

  public typealias Elements = _prext_MapSequence
  
  /// Return a *generator* over the elements of this *sequence*.
  ///
  /// - Complexity: O(1).
  public func generate() -> _prext_MapGenerator<Base.Generator,T> {
    return _prext_MapGenerator(
      _base: _base.generate(), _transform: _transform)
  }

  public var _base: Base
  internal var _transform: (Base.Generator.Element)->T
}

//===--- Collections ------------------------------------------------------===//

/// A `CollectionType` whose elements consist of those in a `Base`
/// `CollectionType` passed through a transform function returning `T`.
/// These elements are computed lazily, each time they're read, by
/// calling the transform function on a base element.
public struct _prext_MapCollection<Base : CollectionType, T>
  : _prext_LazyCollectionType {

  public var startIndex: Base.Index { return _base.startIndex }

  }
}

extension _prext_LazyCollectionType {
  public var _prext_lazy: Self { // Don't re-wrap already-lazy collections
    return self
  }
}

//===--- LazyCollection tests ---------------------------------------------===//

tests.test("LazyCollection/CollectionType") {
