JSONEncoder: Also use workaround on arm

Instead of XFAILing the test try to use the workaround on arm.
This test failed on armv7k.

SR-8276
rdar://43145346
This commit is contained in:
Arnold Schwaighofer
2018-08-16 13:48:42 -07:00
parent 9b29e8dc91
commit 76b03fe907
2 changed files with 2 additions and 5 deletions

View File

@@ -17,7 +17,7 @@
/// runtime when running on i386 simulator. The issue is tracked in https://bugs.swift.org/browse/SR-8276
/// Making the protocol `internal` instead of `fileprivate` works around this issue.
/// Once SR-8276 is fixed, this check can be removed and the protocol always be made fileprivate.
#if arch(i386) && targetEnvironment(simulator)
#if arch(i386) || arch(arm)
internal protocol _JSONStringDictionaryEncodableMarker { }
#else
fileprivate protocol _JSONStringDictionaryEncodableMarker { }
@@ -32,7 +32,7 @@ extension Dictionary : _JSONStringDictionaryEncodableMarker where Key == String,
/// which is needed for the implementation of the key conversion strategy exemption.
///
/// NOTE: Please see comment above regarding SR-8276
#if arch(i386) && targetEnvironment(simulator)
#if arch(i386) || arch(arm)
internal protocol _JSONStringDictionaryDecodableMarker {
static var elementType: Decodable.Type { get }
}