diff options
author | Mike Voorhees <mrvoorhe@users.noreply.github.com> | 2017-03-16 11:59:30 +0300 |
---|---|---|
committer | Marek Safar <marek.safar@gmail.com> | 2017-03-16 11:59:30 +0300 |
commit | 600b36807adeabd10d72fc15ccf129318a4da1b9 (patch) | |
tree | 658797a61e573e99d485997c854d06000c787add /linker | |
parent | 64c25220fca6d0bf225e0aa023080a0f0299255d (diff) |
Sweep assemblies fix (#30)
Diffstat (limited to 'linker')
-rw-r--r-- | linker/Mono.Linker.Steps/SweepStep.cs | 3 | ||||
-rw-r--r-- | linker/Mono.Linker/Annotations.cs | 5 |
2 files changed, 7 insertions, 1 deletions
diff --git a/linker/Mono.Linker.Steps/SweepStep.cs b/linker/Mono.Linker.Steps/SweepStep.cs index c420f8ad5..1d62de6ac 100644 --- a/linker/Mono.Linker.Steps/SweepStep.cs +++ b/linker/Mono.Linker.Steps/SweepStep.cs @@ -29,6 +29,7 @@ using System.Collections; using System.Collections.Generic; +using System.Linq; using Mono.Cecil; using Mono.Collections.Generic; using Mono.Cecil.Cil; @@ -48,7 +49,7 @@ namespace Mono.Linker.Steps { protected override void Process () { - assemblies = Context.GetAssemblies (); + assemblies = Context.Annotations.GetAssemblies ().ToArray (); foreach (var assembly in assemblies) { SweepAssembly (assembly); if ((Annotations.GetAction (assembly) == AssemblyAction.Copy) && diff --git a/linker/Mono.Linker/Annotations.cs b/linker/Mono.Linker/Annotations.cs index ed40b5461..46e92e620 100644 --- a/linker/Mono.Linker/Annotations.cs +++ b/linker/Mono.Linker/Annotations.cs @@ -78,6 +78,11 @@ namespace Mono.Linker { writer.WriteEndAttribute (); } + public ICollection<AssemblyDefinition> GetAssemblies () + { + return assembly_actions.Keys; + } + public AssemblyAction GetAction (AssemblyDefinition assembly) { AssemblyAction action; |