Bug 10884 - Additional abstract members on MethodBase breaks F# build
Summary: Additional abstract members on MethodBase breaks F# build
Status: RESOLVED FIXED
Alias: None
Product: Class Libraries
Classification: Mono
Component: mscorlib ()
Version: master
Hardware: PC All
: --- normal
Target Milestone: Untriaged
Assignee: Marek Safar
URL:
Depends on:
Blocks:
 
Reported: 2013-03-04 13:50 UTC by Chris Ball
Modified: 2013-03-19 22:18 UTC (History)
3 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on GitHub or Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED FIXED

Description Chris Ball 2013-03-04 13:50:48 UTC
F# fails to compile against 3.0.6, where it would compile on 3.0.4. I trace the issue back to this commit:

https://github.com/mono/mono/commit/feb5080d23ca3b0d53a13a77ae39c68734907b6a

The class System.Reflection.MethodBase now has two additional abstract members. The F# source contains classes that derive from MethodBase and MethodInfo, but the additional abstract members in the Mono class prevent building.

Since this class is public exposed, I believe the methods should be converted to virtual, and should throw a NotImplementedException.

I will compile a pull request to cover the fix.
Comment 1 Marek Safar 2013-03-04 16:08:16 UTC
Fixed in master
Comment 2 David Koontz 2013-03-19 22:18:13 UTC
I just tried building with Mono 3.0.6 on OSX and the latest master (5276da1980d8a328f4cd9d3965d05b06ba6cd5b4) and I still am encountering this bug.  I see the commit (8e1ffd9941bbbb374a11f4e9ba64217b19d2cdb8) where this was fixed but the build errors are still occurring:

/Users/dkoontz/dev/fsharp/src/fsharp/FSharp.Data.TypeProviders/TypeProviderEmit.fs(178,6): error FS0365: No implementation was given for 'MethodBase.GetParametersInternal() : ParameterInfo []'

/Users/dkoontz/dev/fsharp/src/fsharp/FSharp.Data.TypeProviders/TypeProviderEmit.fs(178,6): error FS0365: No implementation was given for 'MethodBase.GetParametersCount() : int'

/Users/dkoontz/dev/fsharp/src/fsharp/FSharp.Data.TypeProviders/TypeProviderEmit.fs(178,6): error FS0054: This type is 'abstract' since some abstract members have not been given an implementation. If this is intentional then add the '[<AbstractClass>]' attribute to your type.

/Users/dkoontz/dev/fsharp/src/fsharp/FSharp.Data.TypeProviders/TypeProviderEmit.fs(227,6): error FS0365: No implementation was given for 'MethodBase.GetParametersInternal() : ParameterInfo []'

/Users/dkoontz/dev/fsharp/src/fsharp/FSharp.Data.TypeProviders/TypeProviderEmit.fs(227,6): error FS0365: No implementation was given for 'MethodBase.GetParametersCount() : int'

/Users/dkoontz/dev/fsharp/src/fsharp/FSharp.Data.TypeProviders/TypeProviderEmit.fs(227,6): error FS0054: This type is 'abstract' since some abstract members have not been given an implementation. If this is intentional then add the '[<AbstractClass>]' attribute to your type.