Update assembly loader to account for version numbers
Update assembly loader to account for version numbers

When the default `AssemblyLoadContext` cannot find a dependency of a task assembly (because it does not know where to look) it fires the `Resolving` event, and uses whatever `Assembly` object is returned. Our implementation of the handler simply looks next to each known task assembly and loads and returns the first assembly with a matching short name.

This generally works fine but can be a problem if there are two or more task assemblies that depend on assemblies with the same short name but different versions--the task may ask for version 2.0.0.0, but end up with 1.0.0.0 instead. If it then tries to access an API that does not exist in 1.0.0.0 you'll get an exception.

The fix for this issue is to check the version of a candidate assembly before loading it. If it doesn't match, we simply continue the search until we find one that does (or we run out of candidates).

Related to this is the problem of tasks that were built against an older version of MSBuild. Even if a task was built against 14.0, for example, we want it to use the current version of the MSBuild binaries that ship with msbuild.exe. Since .NET Core does not support binding redirects via config files, we need to handle this ourselves in our `Resolve` handler. If the short name matches one of a well-known set, we update the `AssemblyName` of the requested assembly to use the current version number, and then call back to the default `AssemblyLoadContext` to find it.

mono/msbuild,AndyGerlicher/msbuild,mono/msbuild,Microsoft/msbuild,cdmihai/msbuild,AndyGerlicher/msbuild,Microsoft/msbuild,jeffkl/msbuild,rainersigwald/msbuild,chipitsine/msbuild,sean-gilliam/msbuild,sean-gilliam/msbuild,AndyGerlicher/msbuild,rainersigwald/msbuild,cdmihai/msbuild,mono/msbuild,chipitsine/msbuild,cdmihai/msbuild,cdmihai/msbuild,chipitsine/msbuild,sean-gilliam/msbuild,jeffkl/msbuild,jeffkl/msbuild,Microsoft/msbuild,mono/msbuild,rainersigwald/msbuild,AndyGerlicher/msbuild,jeffkl/msbuild,sean-gilliam/msbuild,chipitsine/msbuild,rainersigwald/msbuild,Microsoft/msbuild