2007/5/25, Michael Foord <[EMAIL PROTECTED]>:
> You could make this conditional by wrapping the import in a 'try..
> except' and having different behaviour on platforms where the .NET type
> is not available (i.e. CPython).

Or, check sys.platform. If you intend to run the same code on both
CPython and IronPython, and if you want some section of code to run
only on IronPython, the best way I found is:

if sys.platform == 'cli':
# IronPython specific

-- 
Seo Sanghyeon
_______________________________________________
users mailing list
[email protected]
http://lists.ironpython.com/listinfo.cgi/users-ironpython.com

Reply via email to