From c25c26b235f7226e2da9c1a222c812835b901341 Mon Sep 17 00:00:00 2001 From: Jonathan Sibley Date: Fri, 21 Oct 2016 16:52:15 -0700 Subject: [PATCH] Explicitly coerce to Any (eliminate Swift 3.0.1 compiler warning) --- JSONCodable/JSONDecodable.swift | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/JSONCodable/JSONDecodable.swift b/JSONCodable/JSONDecodable.swift index 46cf0ba..3cb8095 100644 --- a/JSONCodable/JSONDecodable.swift +++ b/JSONCodable/JSONDecodable.swift @@ -139,7 +139,7 @@ public class JSONDecoder { // JSONCompatible? public func decode(_ key: String) throws -> Compatible? { - return (get(key) ?? object[key]) as? Compatible + return (get(key) ?? object[key] as Any) as? Compatible } // JSONDecodable