Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

initWithCoder has been explicitly marked unavailable error using newest version of Xamarin.iOS

I'm seeing the following error during compile time when working with the latest version of Xamarin.iOS that was released yesterday:

UIActivityViewController.h:23:1: note: 'initWithCoder:' has been explicitly marked unavailable here - (nullable instancetype)initWithCoder:(NSCoder *)aDecoder NS_UNAVAILABLE;

I don't recall ever having this issue before and my code hasn't changed much between the last update and now. Can anyone help me figure out what's going on?

like image 543
whatisyourquest Avatar asked Jun 09 '16 18:06

whatisyourquest


1 Answers

It's a known issue which is harder to diagnose because of a clang bug, i.e. it has nothing to do with UIActivityViewController.

You might be able to workaround this by removing [Export ("initWithCoder:")] inside your code. That should be fine unless your managed object needs to be created from native code. YMMV

like image 93
poupou Avatar answered Oct 17 '22 00:10

poupou