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 Compiler #21

Open
dwsolberg opened this issue Jan 29, 2017 · 3 comments
Open

Swift Compiler #21

dwsolberg opened this issue Jan 29, 2017 · 3 comments

Comments

@dwsolberg
Copy link

main.swift doesn't work on Xcode 8.2 (on January 19, 2017), unless I change to this:

UIApplicationMain(CommandLine.argc, UnsafeMutableRawPointer(CommandLine.unsafeArgv)
.bindMemory(to: UnsafeMutablePointer.self, capacity: Int(CommandLine.argc)), NSStringFromClass(QTouchposeApplication.self), NSStringFromClass(AppDelegate.self))

Also, the instructions would be better if they mentioned that "QTouchposeApplication.h" should be added to the user's Swift bridging header file.

@DAKarp
Copy link

DAKarp commented Feb 6, 2017

Thanks for this!

@Afinque
Copy link

Afinque commented Jun 9, 2017

Thanks, this worked for me as well!

@jonkai
Copy link

jonkai commented Aug 30, 2020

for some more clarification, not positive we need the UnsafeMutableRawPointer any more with xCode 11.x it appears to work fine without it, but let me know if one finds a problem with it, see below:

should include a Bridging header :OculigamiPaint-Bridging-Header.h in the app, with this line in it:#import "QTouchposeApplication.h"

main.swift can look like this then:

import UIKit

UIApplicationMain(
CommandLine.argc,
CommandLine.unsafeArgv,
NSStringFromClass(QTouchposeApplication.self),
NSStringFromClass(AppDelegate.self) //...... replace with the name of your delegate if different
)

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

No branches or pull requests

4 participants