onekiloparsec / SwiftAA

The most comprehensive collection of accurate astronomical algorithms in (C++, Objective-C and) Swift.
http://www.onekiloparsec.dev/
MIT License
172 stars 31 forks source link

Fixed Xcode9 compilation errors while preserving Xcode8 compatibility #69

Closed alex-vasenin closed 7 years ago

alex-vasenin commented 7 years ago

This is probably the minimal changes to fix Xcode9 compilation errors (but not warnings), without breaking Xcode8 compatibility

onekiloparsec commented 7 years ago

Are you sure the compatibility isn't broken? Travis build fails.

https://travis-ci.org/onekiloparsec/SwiftAA/builds/270638631

alex-vasenin commented 7 years ago

I was using Xcode 8.3.3 for testing and it worked fine due to the fact Double.magnitude property was introduced in Xcode 8.3. I replaced it with with plain old abs(), so it should work on any Xcode 8.*

codecov[bot] commented 7 years ago

Codecov Report

Merging #69 into master will decrease coverage by 0.06%. The diff coverage is 44.44%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #69      +/-   ##
==========================================
- Coverage   34.63%   34.57%   -0.07%     
==========================================
  Files         227      227              
  Lines       11252    11240      -12     
==========================================
- Hits         3897     3886      -11     
+ Misses       7355     7354       -1
Impacted Files Coverage Δ
SwiftAA/NumericType.swift 69.44% <44.44%> (-3.18%) :arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 9f2eac6...7208ac7. Read the comment docs.

onekiloparsec commented 7 years ago

Great, thanks.