bennyguitar / Colours

A beautiful set of predefined colors and a set of color methods to make your iOS/OSX development life easier.
MIT License
3.1k stars 301 forks source link

Two Swift Errors #40

Open mstolin opened 9 years ago

mstolin commented 9 years ago

Colours/Colours.swift:148:38: Expression was too complex to be solved in reasonable time; consider breaking up the expression into distinct sub-expressions

// Transfrom XYZ to L*a*b
var deltaF: TransformBlock = { f in
   return (f > pow((6.0/29.0), 3.0)) ? pow(f, 1.0/3.0) : (1/3)*pow((29.0/6.0), 2.0) * f + 4/29.0
}

Colours/Colours.swift:44:41: 'NSString' is not implicitly convertible to 'String'; did you mean to use 'as' to explicitly convert?

var scanner = NSScanner(string: newHex)

Tested on iOS Simulator with iOS 8.4

ghost commented 9 years ago

The first error already have an issue: #35