This project has moved. For the latest updates, please go here.

Will Fasterflect Work on Windows Phone 7?

Mar 22, 2010 at 7:29 PM

Just curious if Fasterflect will compile and work on the new Windows Phone 7?  The phone uses a new version of the Compact Framework?

Has anyone tried it? 

Coordinator
Mar 24, 2010 at 2:14 AM
Edited Mar 24, 2010 at 2:14 AM
To the best of my knowledge the Compact Framework does not support Reflection.Emit, which makes it pretty hard to port Fasterflect. You could possibly use Cecil (from the Mono project, see http://mono-project.com/Cecil for details) to generate code and either create a new or modify an existing assembly. This assembly could then be loaded dynamically. It's likely to be quite a bit of work though and seems somewhat hackish, so consider if you really want to go there.
Coordinator
Mar 24, 2010 at 2:20 AM
Actually it turns out that Windows Phone 7 supports .NET and Silverlight, so it's likely based on either the CLR or the DLR rather than CF. This should make it possible to get Fasterflect running on it, although I haven't tried it. Silverlight support is on the roadmap for future Fasterflect releases, but if you are interested in helping out getting this to work please consider contributing to the project!
Mar 24, 2010 at 10:44 AM
Hi mertner. Thanks for the response.

I loaded up the Windows Phone 7 tools and checked for Reflection.Emit. Unfortunately it's not there. I think the phone is using a new version of the compact framework with Silverlight built in to it. Could be wrong, but that is my understanding.

-Jeff Weber


From: [email removed]
To: [email removed]
Date: Tue, 23 Mar 2010 18:14:07 -0700
Subject: Re: Will Fasterflect Work on Windows Phone 7? [fasterflect:206908]

From: mertner
To the best of my knowledge the Compact Framework does not support Reflection.Emit, which makes it pretty hard to port Fasterflect. You could possibly use Cecil (from the Mono project, see http://mono-project.com/Cecil for details) to generate code and either create a new or modify an existing assembly. The modified assembly could then be loaded dynamically. It's likely to be quite a bit of work though and seems somewhat hackish, so consider if you really want to go there.
Read the full discussion online.
To add a post to this discussion, reply to this email (fasterflect@discussions.codeplex.com)
To start a new discussion for this project, email fasterflect@discussions.codeplex.com
You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.
Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com


Hotmail is redefining busy with tools for the New Busy. Get more from your inbox. Sign up now.
Coordinator
Mar 24, 2010 at 11:40 AM

Unfortunately, Reflection.Emit isn't supposed in Windows Phone 7.  See here.

Oct 18, 2011 at 6:34 PM

As Reflection.Emit is supported in Windows Phone 7 as of Mango, will there be a version of Fasterflect released for the Windows Phone 7 platform?  I tried to use just the base framework with a Mango project, and it almost worked until it hit a TypeInitializationException when trying to load System.Func which apparently doesn't exist in the compact mscorlib.dll.

Coordinator
Oct 18, 2011 at 7:53 PM
Edited Oct 18, 2011 at 7:53 PM

I'm not a Windows Phone owner and therefore would be ill suited to create or test such a port.

However, if the changes required are very limited (as in, isolated to a limited number of source files) then I'm sure we would agree to maintain the changes, if someone else were to do and contribute the initial port.

The hard part of doing the port is to make it compile and subsequently to make the test cases run, to ensure that the code actually works on the target platform. Test cases provide confidence to future maintainers of the code and help avoid regressions, so just making the code compile will not be an option.

Afaicr the build script already cross-compiles for 3.5, 4.0 and SL, so adding in another target is likely not much work.

Let me know if you are anyone else might be interested. I'll be happy to provide guidance to the internals of Fasterflect in the process :-)