Exemple #1
0
        public DependencyContext Merge(DependencyContext other)
        {
            if (other == null)
            {
                throw new ArgumentNullException(nameof(other));
            }

            return(new DependencyContext(
                       Target,
                       CompilationOptions,
                       CompileLibraries.Union(other.CompileLibraries, new LibraryMergeEqualityComparer <CompilationLibrary>()),
                       RuntimeLibraries.Union(other.RuntimeLibraries, new LibraryMergeEqualityComparer <RuntimeLibrary>()),
                       RuntimeGraph.Union(other.RuntimeGraph)
                       ));
        }