Here is a patch to support type using explicit implementation of interfaces.
I took this oportunity to make IorUtil a static type and to avoid call to Repository.GetRepositoryID for ReflectionHelper.MarshalByRefObjectType.
I reverted this patch, 'cause it breaks IntegrationTests\Basic. I also checked it on my real world projects, it breaks them also.
You can run integration tests yourself to find out what is wrong with your patch (nmake && nmake test)
Ok, I have install the missing tool on my side to fully run the integration tests. I will keep you inform of what I find.
Note however that you have also reverted partially the way to compute the repositoryId by replacing use of != by use of Equals. Doing so you invert the test, there is a '!' missing in front of the Equals call. I am surprised that tests are not catching this potential issue.
> Note however that you have also reverted partially the way to compute the
> repositoryId by replacing use of != by use of Equals.
Oops, it was my fault. I fixed this in rev 2017
I just uploaded an other version of the patch that pass the tests. I finally only use a special Marshalling only if the serialized type is an interface. The test was failing because it instance was passed an an Object and .Net RemotingServices do not seems to appreciate it.
I have also added new test to show what can be done with the patch:
- Implement interfaces as internal type, even private
- Implement interfaces explicitely
I have also added some optimization and code cleanup to make some fields readonly which is helpful to understand how types are working.
I haven't had the time to test this one in the integrations test. What are the results of these after it is applied?
I've converted IntegrationTests/Direct to NUnit 2.5 API. And it fails 3 tests with your patch (and 1 without it). So there's still some work to do.
I've just committed a part of your patch (which doesn't break anything) for you to have less local modifications.