Is it really necessary to bridge to objective c like i'm doing for my Doubles below? Seems to work without this step in the playground but doesn't compile in a regular swift file.
Is there a cleaner way?
var prevX = 0.0
var prevY = 0.0
var count = 0
for item : AnyObject in myGraph.vertices {
count++
if let v = item as? Vertex {
x = Double(x)
y = Double(y)
x = x - width / 2.0
y = y - width / 2.0
//var fwidth = Float(width)
var rect = CGRect()
rect.origin.x = x.bridgeToObjectiveC().floatValue
rect.origin.y = y.bridgeToObjectiveC().floatValue
rect.size.width = width.bridgeToObjectiveC().floatValue
rect.size.height = rect.size.width