PostSharp
AOP に 2.1を使用する .net 4.0 アプリケーションを作成しています。Microsoft.Bcl.Asyncが安定したので、このアプリケーションで使用したいと思い
ます。async
ただし、そうすると、次のPostSharp
問題が発生します。
PostSharp.Sdk.CodeModel.AssemblyLoadException: Cannot find assembly 'mscorlib, version=2.0.5.0, culture=neutral, publickeytoken=7cec85d7bea7798e'. [Public key mismatch]
============ PostSharp Assembly Loading Log ===================
LOG: Finding the assembly with binding identity 'mscorlib, version=2.0.5.0, culture=neutral, publickeytoken=7cec85d7bea7798e'.
LOG: Probing location 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\mscorlib.dll' because this file was explicitly added to the search path.
LOG: File 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\mscorlib.dll' has identity 'mscorlib, version=4.0.0.0, culture=neutral, publickeytoken=b77a5c561934e089, processorarchitecture=msil'.
LOG: File 'C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.0\mscorlib.dll' does not match the reference.
これは、コンパイルされるアセンブリが参照System.ServiceModel
し、次のコードを含む場合にのみ発生します。
new FaultContractAttribute(typeof(SomeType));
[__DynamicallyInvokable]
これは、の属性と関係があると推測していSystem.ServiceModel.FaultContractAttribute
ctor
ます。
"Performance critical to inline this type of method across NGen image boundaries".
誰かが同じ問題に遭遇しましたか?