This file contains hidden or 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
| #!/usr/bin/swift | |
| import Foundation | |
| // Models | |
| indirect enum DecisionNode { | |
| case option(Option) | |
| case terminal(Terminal) | |
| } |
This file contains hidden or 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
| import Foundation | |
| import SwiftSyntax // Using 0.50000.0 | |
| // Helper | |
| struct Temporary { | |
| static func makeSwiftFile(withContent content: String) throws -> URL { | |
| let temporaryDirectoryURL = URL(fileURLWithPath: NSTemporaryDirectory(), | |
| isDirectory: true) | |
| let fileName = UUID().uuidString + ".swift" | |
| let temporaryFileURL = |
This file contains hidden or 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
| // | |
| // GameView.swift | |
| // Tilt | |
| // | |
| // Created by Francisco Díaz on 08-06-19. | |
| // Copyright © 2019 Francisco Diaz. All rights reserved. | |
| // | |
| import SwiftUI |
This file contains hidden or 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
| internal protocol StyleType { | |
| var tintColor: UIColor { get } | |
| } | |
| internal struct SomeStyle: StyleType { | |
| let tintColor = UIColor.redColor() | |
| } | |
| internal struct SomeOtherStyle: StyleType { | |
| let tintColor = UIColor.whiteColor() |