From 7544a2535e5a7421b886befd4d90cc652d8a270f Mon Sep 17 00:00:00 2001 From: Krunoslav Zaher Date: Sun, 23 Aug 2015 21:37:09 +0200 Subject: [PATCH] Fixes compile warnings. --- .../RxCollectionViewSectionedAnimatedDataSource.swift | 2 +- .../DataSources/RxCollectionViewSectionedReloadDataSource.swift | 2 +- RxExample/RxExample/Services/HtmlParsing.swift | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/RxDataSourceStarterKit/DataSources/RxCollectionViewSectionedAnimatedDataSource.swift b/RxDataSourceStarterKit/DataSources/RxCollectionViewSectionedAnimatedDataSource.swift index f70ec9d0..31666296 100644 --- a/RxDataSourceStarterKit/DataSources/RxCollectionViewSectionedAnimatedDataSource.swift +++ b/RxDataSourceStarterKit/DataSources/RxCollectionViewSectionedAnimatedDataSource.swift @@ -36,7 +36,7 @@ class RxCollectionViewSectionedAnimatedDataSource : RxColle setSections(c.finalSections) collectionView.performBatchUpdates(c) } - case .Error(let _): + case .Error: #if DEBUG fatalError("Binding error to UI") #endif diff --git a/RxDataSourceStarterKit/DataSources/RxCollectionViewSectionedReloadDataSource.swift b/RxDataSourceStarterKit/DataSources/RxCollectionViewSectionedReloadDataSource.swift index fd3ce7f5..c04f9d0b 100644 --- a/RxDataSourceStarterKit/DataSources/RxCollectionViewSectionedReloadDataSource.swift +++ b/RxDataSourceStarterKit/DataSources/RxCollectionViewSectionedReloadDataSource.swift @@ -22,7 +22,7 @@ class RxCollectionViewSectionedReloadDataSource : RxCollect case .Next(let element): setSections(element) collectionView.reloadData() - case .Error(let error): + case .Error: #if DEBUG fatalError("Binding error to UI") #endif diff --git a/RxExample/RxExample/Services/HtmlParsing.swift b/RxExample/RxExample/Services/HtmlParsing.swift index 274dcdc9..8b818dcb 100644 --- a/RxExample/RxExample/Services/HtmlParsing.swift +++ b/RxExample/RxExample/Services/HtmlParsing.swift @@ -11,7 +11,7 @@ import Foundation func parseImageURLsfromHTML(html: NSString) throws -> [NSURL] { let regularExpression = try NSRegularExpression(pattern: "]*src=\"([^\"]+)\"[^>]*>", options: []) - let matches = regularExpression.matchesInString(html as String, options: [], range: NSMakeRange(0, html.length)) as! [NSTextCheckingResult] + let matches = regularExpression.matchesInString(html as String, options: [], range: NSMakeRange(0, html.length)) return matches.map { match -> NSURL? in if match.numberOfRanges != 2 {