On Wed, 13 Dec 2006 12:09:25 -0800, Nick Alexander <[EMAIL PROTECTED]>  
wrote:
>> I am against enhancing the docstrings as you suggest. I think we should
>> write code to parse the original .pyx files, given the filename and line
>> number information.  There is no extra overhead spacewise, and this fits
>> with how the rest of Python works better.  Also, it is what I already
>> planned to do, but hadn't got to yet  All I did was put something for
>> parsing out the source code -- try ?? on a sagex function.
>
> Okay, this sounds like a good task for me.

I'd be very happy if you were to do this.  Thanks!

>  I personally am not
> comfortable with ad-hoc parsing, so I avoid it like the plague, but
> I'll take a look at inspect and see what the 'officially sanctioned'
> technique is.

Keep in mind that as languages go, Python is very easy to parse.
E.g., if f is a function definition:

def f(x):
    blah

It's really easy to know where the definition ends.

> On an unrelated note, is there a reason that ?, ??, hg_sage.diff(), etc
> use the pager as opposed to printing normally?  Is this configurable?

For ?, ?? this is an IPython question.  I think for IPython
this is determined by the environment variable PAGER.
For hg, less is used except in the notebook.  This should be changed
(by changing part of misc/hg.py) to use the environment variable
PAGER instead, and default to less.  Feel free to send me a patch.

William

--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to sage-devel@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/sage-devel
URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/
-~----------~----~----~----~------~----~------~--~---

Reply via email to