Giter Site home page Giter Site logo

ante's Issues

Swift 2 Error

ante.swift:47:10: error: expected identifier in function declaration
    func repeat(n: Int) -> String {
         ^
ante.swift:32:29: error: missing argument label 'arrayLiteral:' in call
        return String(Array(self)[i])
                            ^
                            arrayLiteral:
ante.swift:36:16: error: use of unresolved identifier 'countElements'
        return countElements(self)
               ^
ante.swift:53:21: error: cannot invoke initializer for type 'NSRegularExpression' with an argument list of type '(pattern: String, options: NilLiteralConvertible, error: NilLiteralConvertible)'
        let regex = NSRegularExpression(pattern: pattern, options: nil, error: nil)
                    ^
ante.swift:53:21: note: overloads for 'NSRegularExpression' exist with these partially matching parameter lists: (pattern: String, options: NSRegularExpressionOptions), (), (coder: NSCoder)
        let regex = NSRegularExpression(pattern: pattern, options: nil, error: nil)
                    ^
ante.swift:204:54: error: expected member name following '.'
                let label = "Q\(Int(card.suit).chr)".repeat(Int(suit / card.suit))
                                                     ^
ante.swift:204:54: error: consecutive statements on a line must be separated by ';'
                let label = "Q\(Int(card.suit).chr)".repeat(Int(suit / card.suit))
                                                     ^
                                                     ;
ante.swift:204:60: error: expected '{' after 'repeat'
                let label = "Q\(Int(card.suit).chr)".repeat(Int(suit / card.suit))
                                                           ^
<unknown>:0: error: expected 'while' after body of 'repeat' statement
ante.swift:275:5: error: 'println' has been renamed to 'print'
    println("usage: ante.swift filename.ante");
    ^~~~~~~
    print
Swift.println:1:33: note: 'println' has been explicitly marked unavailable here
@available(*, unavailable) func println<T>(value: T)
                                ^
ante.swift:105:23: error: cannot invoke initializer for type 'NSString' with an argument list of type '(contentsOfFile: String, encoding: UInt, error: inout NSError?)'
        let program = NSString(contentsOfFile: fileName, encoding: NSUTF8StringEncoding, error: &error)
                      ^
ante.swift:105:23: note: overloads for 'NSString' exist with these partially matching parameter lists: (unicodeScalarLiteral: StaticString), (extendedGraphemeClusterLiteral: StaticString), (stringLiteral: StaticString), (string: NSString), (), (coder: NSCoder), (characters: UnsafePointer<unichar>, length: Int), (UTF8String: UnsafePointer<Int8>), (string: String), (format: String, arguments: CVaListPointer), (data: NSData, encoding: UInt), (bytesNoCopy: UnsafeMutablePointer<Void>, length: Int, encoding: UInt, freeWhenDone: Bool), (CString: UnsafePointer<Int8>, encoding: UInt), (contentsOfURL: NSURL, encoding: UInt), (contentsOfFile: String, encoding: UInt), (contentsOfURL: NSURL, usedEncoding: UnsafeMutablePointer<UInt>), (contentsOfFile: String, usedEncoding: UnsafeMutablePointer<UInt>), (contentsOfFile: String), (contentsOfURL: NSURL), (CString: UnsafePointer<Int8>, length: Int), (CString: UnsafePointer<Int8>)
        let program = NSString(contentsOfFile: fileName, encoding: NSUTF8StringEncoding, error: &error)
                      ^
ante.swift:137:26: error: 'enumerate' is unavailable: call the 'enumerate()' method on the sequence
        for (i, line) in enumerate(lines) {
                         ^~~~~~~~~
Swift.enumerate:1:90: note: 'enumerate' has been explicitly marked unavailable here
@available(*, unavailable, message="call the 'enumerate()' method on the sequence") func enumerate<Seq : SequenceType>(base: Seq) -> EnumerateSequence<Seq>
                                                                                         ^
ante.swift:139:52: error: ambiguous use of operator '+'
            self.code.append(Card(rank: 0, suit: i + 1))
                                                   ^
Swift.+:1:26: note: found this candidate
@warn_unused_result func +<T : Strideable>(lhs: T.Stride, rhs: T) -> T
                         ^
Swift.+:1:6: note: found this candidate
func +<T : UnsignedIntegerType>(lhs: T._DisallowMixedSignArithmetic, rhs: T) -> T
     ^
ante.swift:255:43: error: use of unresolved identifier '&/'
                        initial = initial &/ rank
                                          ^
ante.swift:255:43: error: operator is not a known binary operator
                        initial = initial &/ rank
                                          ^
ante.swift:255:43: error: operator is not a known binary operator
                        initial = initial &/ rank
                                          ^
ante.swift:267:9: error: 'println' has been renamed to 'print'
        println("Ante exception: \(message) on line \(self.line) (pc:\(self.pc))")
        ^~~~~~~
        print
Swift.println:1:33: note: 'println' has been explicitly marked unavailable here
@available(*, unavailable) func println<T>(value: T)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.