Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update XML API for Swift 5.1 on Linux #216

Merged
merged 2 commits into from
Aug 29, 2019
Merged

Update XML API for Swift 5.1 on Linux #216

merged 2 commits into from
Aug 29, 2019

Conversation

keith
Copy link
Contributor

@keith keith commented Aug 27, 2019

With Swift 5.1 corelibs foundation introduced a new module called
FoundationXML and moved all XMLParser related API there. This adds
compatibility for that while still supporting Swift 5.0

With Swift 5.1 corelibs foundation introduced a new module called
FoundationXML and moved all XMLParser related API there. This adds
compatibility for that while still supporting Swift 5.0
@keith
Copy link
Contributor Author

keith commented Aug 27, 2019

Ok it looks like Swift 4.x doesn't support allow using the canImport directive. If you want to keep supporting that version I can attempt to wrap this in an #if compiler(>=5.0)

@codecov-io
Copy link

codecov-io commented Aug 27, 2019

Codecov Report

Merging #216 into master will not change coverage.
The diff coverage is 100%.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #216   +/-   ##
=======================================
  Coverage   78.56%   78.56%           
=======================================
  Files          13       13           
  Lines        2398     2398           
=======================================
  Hits         1884     1884           
  Misses        514      514
Impacted Files Coverage Δ
Source/SWXMLHash.swift 82.9% <100%> (ø) ⬆️

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 41c3ff5...b2f5871. Read the comment docs.

@keith
Copy link
Contributor Author

keith commented Aug 27, 2019

I've pushed that to see if CI is happy with it at least

@drmohundro
Copy link
Owner

@keith thanks for the PR! I was actually about to respond but it looks like you noticed that already. I'm also fine with bumping the SWIFT_VERSION to 5.0 in the .travis.yml file. It might be worthwhile to bump the major version if it will be using 5+ specific features, but I'm fine with that. The versioning has more or less followed the Swift version numbers anyway.

@keith
Copy link
Contributor Author

keith commented Aug 27, 2019

Up to you! But if this iteration works I guess you can decide to do that independently of adding 5.1 support

@drmohundro
Copy link
Owner

Yep, still doesn't like that flag either...

Compile Swift Module 'SWXMLHash' (3 sources)
/home/travis/build/drmohundro/SWXMLHash/Source/SWXMLHash.swift:33:5: error: unexpected platform condition (expected 'os', 'arch', or 'swift')
#if compiler(>=5.1)
    ^

I'm happy to make the change tomorrow or let you if you if you can get to it sooner.

Copy link
Owner

@drmohundro drmohundro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@drmohundro drmohundro merged commit 3d020ae into drmohundro:master Aug 29, 2019
@keith
Copy link
Contributor Author

keith commented Aug 29, 2019

Thanks!

@drmohundro
Copy link
Owner

I'll get 5.0.0 tagged/released shortly. Thanks again for the contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants