-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[#97] Rename
CRApplication{Delegate}
to `Criollo.Application{Delega…
…te}` and refine `CRApplicationMain`
- Loading branch information
1 parent
327d5b6
commit 4d2c272
Showing
7 changed files
with
88 additions
and
57 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
// | ||
// Application.swift | ||
// | ||
// | ||
// Created by Cătălin Stan on 16/09/2022. | ||
// | ||
|
||
@_exported import Criollo | ||
|
||
public class Criollo { | ||
public static func applicationMain(_ delegate: ApplicationDelegate) throws { | ||
let res = __CRApplicationMain(CommandLine.argc, CommandLine.unsafeArgv, delegate) | ||
if res != EXIT_SUCCESS { | ||
throw NSError(domain: NSPOSIXErrorDomain, code: Int(res), userInfo: [NSLocalizedDescriptionKey : strerror(res) ?? "The application returned an unknown error code."]) | ||
} | ||
} | ||
} |