Maciej Fijalkowski wrote: > On Wed, Feb 24, 2010 at 6:35 AM, Nick Coghlan <ncoghlan at gmail.com> wrote: >> Tarek Ziadé wrote: >>> That makes me wonder : why don't we have a sys.implementation variable ? >>> (cython/jython/pypi), since we can have several values for cython in >>> sys.platform > > Hello. > > So I propose to have a sys.implementation which would have string > representation like "CPython" or "Jython" and have a couple of extra > attributes on that. I can think about a lot of attributes, however, > couple comes to mind as obvious. > > * supports_c_api - whether it can load and use CPython C modules > * gc_strategy - probably equals "refcounting" or not, useful for some people > * frame_introspection - This is mostly True for everybody except > IronPython which has it as an optional command line argument. Might be > useful to have it for some projects, unsure. > > What do you think? I think anything along these lines needs to be a PEP so that the developers of the different implementations all get a chance to comment and then have a firm standard to code to afterwards :) Christian was going to write one in the PEP 370 context, so it's worth following up with him to see if he ever got around to drafting anything. Cheers, Nick. -- Nick Coghlan | ncoghlan at gmail.com | Brisbane, Australia ---------------------------------------------------------------
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4