Closed aalmada closed 7 years ago
I was naughty and renamed projects and classes in #7. Could you re-apply your changes on master?
No problem. I like the new names.
@mikhailshilkov I fixed the build but please don't merge yet. It's still not working.
@mikhailshilkov Passing all tests. I'd like to test it a real project build. How do you do it?
You can build a package with a new version, make a local NuGet feed (from local folder) and put the package there. Or just hack-copy the dll to your packages folder and rebuild.
Looks like the referenced type is not resolved correctly. :(
2>MSBUILD : error : Fody: An unhandled exception occurred:
2>MSBUILD : error : Exception:
2>MSBUILD : error : Value cannot be null.
2>MSBUILD : error : Parameter name: type
2>MSBUILD : error : StackTrace:
2>MSBUILD : error : at Mono.Cecil.ModuleDefinition.ImportReference(TypeReference type, IGenericParameterProvider context)
2>MSBUILD : error : at Mono.Cecil.ModuleDefinition.ImportReference(TypeReference type)
2>MSBUILD : error : at ModuleWeaver.GetAllProperties(TypeReference type)
2>MSBUILD : error : at ModuleWeaver.GetAllProperties(TypeDefinition type)
2>MSBUILD : error : at ModuleWeaver.GetAllProperties(TypeReference type)
2>MSBUILD : error : at ModuleWeaver.GetAllProperties(TypeDefinition type)
2>MSBUILD : error : at ModuleWeaver.<>cDisplayClass19_0.1 source, Func
2 predicate)
2>MSBUILD : error : at ModuleWeaver.<>cDisplayClass19_0.1.<CombinePredicates>b__0(TSource x) 2>MSBUILD : error : at System.Linq.Enumerable.WhereEnumerableIterator
1.MoveNext()
2>MSBUILD : error : at System.Linq.Enumerable.Aggregate[TSource,TAccumulate](IEnumerable1 source, TAccumulate seed, Func
3 func)
2>MSBUILD : error : at ModuleWeaver.GetValidConstructor(TypeDefinition type)
2>MSBUILD : error : at ModuleWeaver.Execute()
2>MSBUILD : error : at lambda_method(Closure , Object )
2>MSBUILD : error : at InnerWeaver.ExecuteWeavers() in C:\projects\fody\FodyIsolated\InnerWeaver.cs:line 161
2>MSBUILD : error : at InnerWeaver.Execute() in C:\projects\fody\FodyIsolated\InnerWeaver.cs:line 82
2>MSBUILD : error : Source:
2>MSBUILD : error : Mono.Cecil
2>MSBUILD : error : TargetSite:
2>MSBUILD : error : Mono.Cecil.TypeReference ImportReference(Mono.Cecil.TypeReference, Mono.Cecil.IGenericParameterProvider)
2>MSBUILD : error :
The exception happens if the referenced assembly is a PCL :o
@mikhailshilkov Everything's working! Looks like Cecil only supports PCL Profile433.
@mikhailshilkov Tested now on my work project and it does work on a multi-assembly build.
I don't have this case in my projects... Time to integrate?
@mikhailshilkov Unless you have comments about the code
This is my attempt to add support for inheritance with classes in different assemblies but in the same folder. This would be the most common scenario. Added assembly resolvers in weaver and in the tests but the module is still not saving successfully. @mikhailshilkov Do you experience with assembly/type resolution in Cecil?