Merge pull request #40 from kevindeleon/patch-1

Corrects code that would fail due to type mismatch
This commit is contained in:
Rob Rix 2015-06-04 09:44:38 -04:00
Родитель dec6f540b2 e102e26b2d
Коммит 63b35a8f7f
1 изменённых файлов: 2 добавлений и 2 удалений

Просмотреть файл

@ -190,7 +190,7 @@ class Vehicle {
}
func maximumTotalTirePressure(pressurePerWheel: Float) -> Float {
return pressurePerWheel * numberOfWheels
return pressurePerWheel * Float(numberOfWheels)
}
}
@ -215,7 +215,7 @@ protocol Vehicle {
}
func maximumTotalTirePressure(vehicle: Vehicle, pressurePerWheel: Float) -> Float {
return pressurePerWheel * vehicle.numberOfWheels
return pressurePerWheel * Float(vehicle.numberOfWheels)
}
struct Bicycle: Vehicle {