Marshal
Marshal copied to clipboard
Getting Error : Ambiguous reference to member 'value(for:inContext:)'
Hi,
I have just started exploring the Marshal and tried to build some Demo, using carthage.
But getting error : Ambiguous reference to member 'value(for:inContext:)'
Line of code in my project :
let obj = personsJSON() let context = DeserializationContext() let people: [Person] = try! obj.value(for: "people", inContext: context) // Getting error on this line
Can you please check and let me know whats the issue.
Thank you Nitesh
I had the same issue. Please insert this code in do {} catch {}
(remove ! after try) statement and check whats going on. Maybe it will show another error. Also check if your person class implements these two protocols UnmarshalingWithContext, UnmarshalUpdatingWithContext
Milczi