MyXmlNodeList extensionMethods = new MyXmlNodeList ();
+ HashSet<string> forwardedTypes = new HashSet<string> ();
+
public override void Run (IEnumerable<string> args)
{
show_exceptions = DebugOutput;
this.assemblies = assemblies.Select (a => LoadAssembly (a)).ToList ();
+ // Store types that have been forwarded to avoid duplicate generation
+ GatherForwardedTypes ();
+
docEnum = docEnum ?? new DocumentationEnumerator ();
// PERFORM THE UPDATES
}
}
+ void GatherForwardedTypes ()
+ {
+ foreach (var asm in assemblies)
+ foreach (var type in asm.MainModule.ExportedTypes.Where (t => t.IsForwarder).Select (t => t.FullName))
+ forwardedTypes.Add (type);
+ }
+
static ExceptionLocations ParseExceptionLocations (string s)
{
ExceptionLocations loc = ExceptionLocations.Member;
{
foreach (TypeDefinition type in docEnum.GetDocumentationTypes (assembly, null)) {
string typename = GetTypeFileName(type);
- if (!IsPublic (type) || typename.IndexOfAny (InvalidFilenameChars) >= 0)
+ if (!IsPublic (type) || typename.IndexOfAny (InvalidFilenameChars) >= 0 || forwardedTypes.Contains (type.FullName))
continue;
string reltypepath = DoUpdateType (type, source, dest);
(from i in values.Keys
where (c & i) != 0
select typename + "." + values [i])
- .ToArray ());
+ .DefaultIfEmpty (v.ToString ()).ToArray ());
}
return "(" + GetDocTypeFullName (valueType) + ") " + v.ToString ();
}