     static var max : Double { return DBL_MAX }
     static var min : Double { return DBL_MIN }
     public func successor() -> Double {
-        return nextafter(self, self + 1)
+        return nextafter(self, DBL_MAX)
     }
 }
 


// partially from source: http://natecook.com/blog/2014/08/generic-functions-for-incompatible-types/

protocol NumericType : ForwardIndexType, Hashable, Strideable {
    
    func &+(lhs: Self, rhs: Self) -> Self
    func &-(lhs: Self, rhs: Self) -> Self

    static var max : Float { return FLT_MAX }
    static var min : Float { return FLT_MIN }
    public func successor() -> Float {
        return nextafterf(self, FLT_MAX)
    }
}

