Skip to content

Commit a186906

Browse files
authored
fixed #1 and #2
1 parent 11069ee commit a186906

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/CSharpTypePrinter/CSharpTypePrinter.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,7 +86,7 @@ public static string ToCSharpCode(this Type type,
8686

8787
var typeArgsConsumedByParentsCount = 0;
8888
var s = new StringBuilder();
89-
if (!stripNamespace)
89+
if (!stripNamespace && !string.IsNullOrEmpty(type.Namespace)) // for the auto-generated classes Namespace may be empty and in general it may be empty
9090
s.Append(type.Namespace).Append('.');
9191

9292
if (parentTypes != null)

0 commit comments

Comments
 (0)