Error Handling in Swift 3
<p>I'm migrating my code over to Swift 3 and see a bunch of the same warnings with my do/try/catch blocks. I want to check if an assignment doesn't return nil and then print something out to the console if it doesn't work. The catch block says it "is unreachable because no errors are thrown in 'do' block". I would want to catch all errors with one catch block.</p>

<pre><code>let xmlString: String?
    do{
        //Warning for line below: "no calls to throwing function occurs within 'try' expression
        try xmlString = String(contentsOfURL: accessURL, encoding: String.Encoding.utf8)

        var xmlDict = XMLDictionaryParser.sharedInstance().dictionary(with: xmlString)
        if let models = xmlDict?["Cygnet"] {
            self.cygnets = models as! NSArray
        }

    //Warning for line below: "catch block is unreachable because no errors are thrown in 'do' block
    } catch {
        print("error getting xml string")
    }
</code></pre>

<p>How would I write a proper try catch block that would handle assignment errors?</p>