[IronPython] Referenced Assemblies with DLR languages

Doug Blank doug.blank at gmail.com
Tue Jan 11 14:13:26 CET 2011

Two questions about referenced assemblies (which are really perhaps
DLR questions):

1) I'd like to be able to use different names than are used in a DLL.
For example, say I have a Library.dll, and it has a class
"ReallyBadName". Is there an easy way that I can rename or alias
ReallyBadName after I add a reference to Library? I'd like this to
work for all of my DLR languages, so I'd like to do it right after I
add the reference, rather than, say, doing it in Python with "import
ReallyBadName as GoodName"---but that is the effect I want.

2) Is there a way that I could have a Library.dll bring in other
assemblies so that they would be available to DLR languages? Of
course, one could load an assembly in an assembly that you
clr.AddReference, but that wouldn't make it available to all of the
DLR languages right? It seems that one would need a callback where the
clr was passed into the assembly which was clr.AddReference-ed, so
that it could add references too. Could I overload the clr importer to
do that? Or is there a better way?

Thanks for any pointers,


More information about the Ironpython-users mailing list