[Mono-devel-list] Assembly versioning

John Luke jluke at users.sourceforge.net
Sun May 16 19:24:45 EDT 2004


Marcus wrote:

>Mono's behavior does conform to the spec, but the spec also permits the 
>runtime to ignore version numbers. I do not know exactly what .NET does. When 
>I say "version number," I mean the entire four-component A:B:C:D field. Under 
>what circumstances does .NET require an exact match? And does it really 
>require an exact match in all four components of the version, or just major 
>and minor numbers?
>
>My point is that Mono should be at least as permissive as .NET with regard to 
>loading assemblies. From what I see, the ECMA spec is agnostic with regard to 
>the GAC. So I really think the behavior needs to be empiracally derived to 
>follow .NET as reasonably as possible.
>
>I'm attached an example of the disassembled code (since I do not know if 
>binaries work in the mailing list). The corresponding executable works 
>on .NET, Pnet, and Rotor, but fails on Mono with
>  
>
I'm pretty sure just A:B are meant to determine which version the 
runtime is to load.  Supposedly .NET will load the A:B version with the 
highest C:D (build:revision) number according to the C# book I have.

"When two assemblies have different major or minor numbers, they are 
considered to be incompatible. ... When an application loads an 
assembly, it specifies the major and minor version it wants, and the 
AssemblyResolver finds the highest build and revision numbers."

Which doesn't explain why they think asking for version 1.2 is ok for 
them to load the 1.0 version of System.Xml on .NET, but perhaps they 
didn't expect anyone to use higher numbers then they did yet.  Perhaps, 
they are actually falling back to load only on the Major version.



More information about the Mono-devel-list mailing list