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

Swift 3.0 Migration #1951

Closed
wants to merge 21 commits into from
Closed

Swift 3.0 Migration #1951

wants to merge 21 commits into from

Conversation

sleroux
Copy link

@sleroux sleroux commented Jun 27, 2016

WIP for Swift 3.0 migration.

Current strategy is to go piece by piece through each framework/target and use the migrator which so far has been pretty solid.

@sleroux sleroux added wip Do Not Merge ⛔️ This issue is a work in progress and is not ready to land labels Jun 27, 2016
@varkor
Copy link
Contributor

varkor commented Jul 12, 2016

All of our own internal code has no been migrated to Swift 3.0. Now, we just need to update our dependencies to Swift 3.0 versions.

It appears that a number of incompatibilities with Swift 3.0 in SQLite did not get caught by the migrator, or the compiler initially. It would be better if we could use an updated version once it is available.

@farhanpatel
Copy link
Contributor

woo! Thats an impressive number of changes. I'm curious, was the migrator tool helpful? Or did you have to manually convert things?

@varkor
Copy link
Contributor

varkor commented Jul 12, 2016

The migration assistant does lots of the heavy lifting, but there are a couple of areas it stumbles with (some name collisions, certain places optionals aren't being handled in the best way, some random issues it didn't seem to pick up on). Also, the naming convention for methods has changed with Swift to favour explicit named first parameters over overly-descriptive method names, so there was quite a lot of refactoring too. There are a lot of methods, though, so there are probably a few that slipped through the net.

@sleroux
Copy link
Author

sleroux commented Jul 18, 2016

Hey @varkor thanks a ton for picking this up! There were a ton of changes needed to be made in the Client/Sync targets and that was no small task. Really happy to have these changes made so we can just wait for the dependencies to update instead of the other way around!

@farhanpatel
Copy link
Contributor

farhanpatel commented Jul 20, 2016

Dependencies that still need to migrate to 3.0

@varkor
Copy link
Contributor

varkor commented Jul 20, 2016

I've taken a look through the first few commits, and made some changes to hopefully make the method names more Swift 3.0-y. Could do with someone looking through at some change to make sure they all seem sensible, though.

@bytegh
Copy link

bytegh commented Aug 29, 2016

Hey, guys:

so I we start to use this PR in my project(migrated to swift3.0 already). Or I still need to wait?

thanks! this is a amazing library :)

@skreutzberger
Copy link

skreutzberger commented Sep 12, 2016

Why don’t you guys switch to SwiftyBeaver for logging on debug and release?

Besides being more easier-to-use, feature-rich, more actively developed with a much larger, more active userbase, it is also supporting the latest Swift 3 GM. This week the swift3 branch will be even merged into master and will become the new standard.

Disclaimer: I am the author 😬

@rajmohangoaugment
Copy link

is the swift 3.0 is in progress or not happening anytime soon ? I would prefer to wait if its happening since i may avoid duplication of conversion work.

addSubview(matchCountView)

previousButton.setImage(UIImage(named: "find_previous"), forState: UIControlState.Normal)
previousButton.setTitleColor(FindInPageUX.ButtonColor, forState: UIControlState.Normal)
previousButton.setImage(UIImage(named: "find_previous"), for: UIControlState())
Copy link
Contributor

Choose a reason for hiding this comment

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

This should be UIControlState.normal not UIControlState() as should the others below

@fluffyemily fluffyemily deleted the swift-3.0-migration branch February 14, 2017 17:13
isabelrios pushed a commit to isabelrios/firefox-ios that referenced this pull request Feb 19, 2024
…bile#2045)

Co-authored-by: Bogdan Cernea <bogdan.cernea@softvision.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Do Not Merge ⛔️ This issue is a work in progress and is not ready to land
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants