Search code examples
silverlight-5.0system.reflectionportable-class-library

Can't see ICustomTypeProvider in .Net Portable Subset


I created a portable class library in a project to hold some common code inside a Silverlight 5 solution. I would like to implement the ICustomTypeProvider to create some flexible objects, but I can't see the interface in the PCL, even if I only choose the .Net Framework and SL5 to be the targets for the library.

System.Reflection appears in both the 4.5 framework and SL5, so why can't I see the interface?


Solution

  • I asked the same question in the Visual Studio Gallery Portable Library Tools Discussion (search for question titled ICustomTypeProvider currently on page 2, I can't link it directly, what are MS thinking).

    Reply by David M. Kean:

    Currently the missing types issue is a point-in-time issue (ie it will get better in the future), and comes down due to our lack of thinking about "portability" when we were working on down-level platforms and APIs. On newer platforms (Windows Store apps, .NET 4.5), we expose the true subset, ie everything that is common between Windows Store apps and .NET 4.5 is consumable from portable. The same will be true for newer versions of unannounced platforms.