From 54bd312f8de72d4ca109fb12351b44203a482d23 Mon Sep 17 00:00:00 2001 From: "Janne R." Date: Tue, 26 Aug 2014 20:48:35 +0300 Subject: Use preferred shorthand syntax for dictionary type --- swift.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'swift.html.markdown') diff --git a/swift.html.markdown b/swift.html.markdown index a47b085a..a0ea8519 100644 --- a/swift.html.markdown +++ b/swift.html.markdown @@ -39,7 +39,7 @@ var occupations = [ "kaylee": "Mechanic" ] occupations["Jayne"] = "Public Relations" -let emptyDictionary = Dictionary() +let emptyDictionary = [String: Float]() // -- cgit v1.2.3 From c9400c2a7d5262651884fffecda83ace1bfc4d97 Mon Sep 17 00:00:00 2001 From: Assaf Gelber Date: Thu, 28 Aug 2014 14:00:25 +0300 Subject: Change swift class name to Square --- swift.html.markdown | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'swift.html.markdown') diff --git a/swift.html.markdown b/swift.html.markdown index a0ea8519..6d98b067 100644 --- a/swift.html.markdown +++ b/swift.html.markdown @@ -157,7 +157,7 @@ print(numbers) // [3, 6, 18] // structured object, you should use a `struct` // A simple class `Square` extends `Shape` -class Rect: Shape { +class Square: Shape { var sideLength: Int = 1 // Custom getter and setter property -- cgit v1.2.3