On Jun 7, 2012 12:20 AM, "Yury Selivanov" <yselivanov...@gmail.com> wrote:

>
> I agree, that we shouldn't make 'functools' be dependent on 'inspect'
module.
> Moreover, this is not even currently possible, as it creates an
import-loop
> that is hard to untie.  But how about the following:
>
> 1. Separate 'Signature' object from 'inspect' module, and move it to a
> private '_signature.py' (that will depend only on
'collections.OrderedDict',
> 'itertools.chain' and 'types')
>
> 2. Publish it in the 'inspect' module
>
> 3. Make 'signature' method to work with any callable
>
> 4. Make 'Signature' class to accept only functions
>
> 5. Import '_signature' in the 'functools', and use 'Signature' class
> directly, as it will accept just plain functions.
>
> Would this work?

Sounds like a good plan to me.

Cheers,
Nick.

--
Sent from my phone, thus the relative brevity :)
>
> -
> Yury
>
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to