Permalink
Browse files

CLJCLR-13: Add namespace DescriptionAttribute to init type

  • Loading branch information...
Aaron Craelius authored and dmiller committed Mar 28, 2013
1 parent 3da1f6e commit 01b46505ac902e3a1ad2167ad0b0e0689d45f716
Showing with 6 additions and 0 deletions.
  1. +6 −0 Clojure/Clojure/CljCompiler/Compiler.cs
@@ -14,6 +14,7 @@
using System;
using System.Collections.Generic;
+using System.ComponentModel;
using System.Text;
using System.IO;
using System.Threading;
@@ -1350,6 +1351,11 @@ public static object Compile(GenContext context,TextReader rdr, string sourceDir
cbGen.EndExceptionBlock();
cbGen.Emit(OpCodes.Ret);
+ var descAttrBuilder =
+ new CustomAttributeBuilder(typeof (DescriptionAttribute).GetConstructor(new[] {typeof (String)}),
+ new [] {String.Format("{{:clojure-namespace {0}}}", CurrentNamespace)});
+ initTB.SetCustomAttribute(descAttrBuilder);
+
initTB.CreateType();
}
catch (LispReader.ReaderException e)

0 comments on commit 01b4650

Please sign in to comment.