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
enum TestEnum { | |
case e1 | |
case e2 | |
} | |
let a: Any = TestEnum.e1 | |
let b: Any = TestEnum.e2 | |
let q = (a == b) // <--- error here |
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
class Test { | |
func testFunc<T>() -> [T] { | |
var list = [T]() | |
return list | |
} | |
} |
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
func test(text: String, value: Int) { | |
println(text) | |
println(value) | |
} | |
test("Hallo", 4) | |
class Test { | |
class func test(text: String, value: Int) { | |
println(text) |
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
#!/bin/bash | |
HOME=/var/services/homes/backupchef | |
SNAPSHOT_DIR=$HOME/backups/myserver | |
LOG_DIR=$HOME/backups | |
KEY_ID=$HOME/.ssh/id_rsa | |
RM=/bin/rm; | |
MV=/bin/mv; | |
CP=/bin/cp; | |
$RM -rf $SNAPSHOT_DIR/daily.6; |
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
class Test { | |
var testVar: Int = 0 { | |
didSet { | |
println("Hello") | |
} | |
} | |
init(bla: Int) { | |
self.testVar = bla | |
} |